1
0
mirror of https://github.com/oliverbooth/TcpDotNet synced 2024-11-23 01:08:47 +00:00

Compare commits

...

6 Commits

6 changed files with 14 additions and 4 deletions

View File

@ -1,4 +1,4 @@
<h1 align="center">TcpDotNet</h1>
<h1 align="center"><img src="branding_Banner.png" alt="TCP.NET"></h1>
<p align="center">
<a href="https://github.com/oliverbooth/TcpDotNet/actions/workflows/dotnet.yml"><img src="https://img.shields.io/github/actions/workflow/status/oliverbooth/TcpDotNet/dotnet.yml?branch=main&style=flat-square" alt="GitHub Workflow Status" title="GitHub Workflow Status"></a>
<a href="https://github.com/oliverbooth/TcpDotNet/issues"><img src="https://img.shields.io/github/issues/oliverbooth/TcpDotNet?style=flat-square" alt="GitHub Issues" title="GitHub Issues"></a>

View File

@ -11,6 +11,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
.gitignore = .gitignore
LICENSE.md = LICENSE.md
README.md = README.md
branding_Banner.png = branding_Banner.png
branding_Icon.png = branding_Icon.png
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Workflows", "Workflows", "{0FAB77D5-AAE4-4722-A5F4-88A239858D65}"

View File

@ -82,7 +82,7 @@ public sealed class ProtocolClient : ClientNode
BaseSocket = new Socket(remoteEP.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
try
{
await Task.Run(() => BaseSocket.ConnectAsync(remoteEP, cancellationToken), cancellationToken);
await BaseSocket.ConnectAsync(remoteEP, cancellationToken);
}
catch
{
@ -95,8 +95,7 @@ public sealed class ProtocolClient : ClientNode
State = ClientState.Handshaking;
var handshakeRequest = new HandshakeRequestPacket(ProtocolVersion);
var handshakeResponse =
await SendAndReceiveAsync<HandshakeResponsePacket>(handshakeRequest, cancellationToken);
var handshakeResponse = await SendAndReceiveAsync<HandshakeResponsePacket>(handshakeRequest, cancellationToken);
if (handshakeResponse.HandshakeResponse != HandshakeResponse.Success)
{

View File

@ -12,6 +12,7 @@
<RepositoryType>git</RepositoryType>
<Description>A TCP library for .NET with support for AES encryption.</Description>
<PackageLicenseFile>LICENSE.md</PackageLicenseFile>
<PackageIcon>branding_Icon.png</PackageIcon>
<PackageTags>dotnet networking encryption tcp</PackageTags>
<VersionPrefix>0.1.0</VersionPrefix>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
@ -40,10 +41,18 @@
</ItemGroup>
<ItemGroup>
<None Include="..\branding_Icon.png">
<Pack>True</Pack>
<PackagePath/>
</None>
<None Include="..\LICENSE.md">
<Pack>True</Pack>
<PackagePath/>
</None>
<None Include="..\README.md">
<Pack>True</Pack>
<PackagePath/>
</None>
</ItemGroup>
</Project>

BIN
branding_Banner.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
branding_Icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB