Skip to content

Commit

Permalink
Target netstandard1.3 instead of netstandard1.5
Browse files Browse the repository at this point in the history
  • Loading branch information
tmds committed Jul 22, 2016
1 parent 039c84b commit aac4f08
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions src/Tmds.MDns/NetworkInterfaceHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public NetworkInterfaceHandler(ServiceBrowser serviceBrowser, NetworkInterface n
ServiceBrowser = serviceBrowser;
NetworkInterface = networkInterface;
_index = NetworkInterface.GetIPProperties().GetIPv4Properties().Index;
#if NETSTANDARD1_5
#if NETSTANDARD1_3
_queryTimer = new Timer(OnQueryTimerElapsed, null, Timeout.Infinite, Timeout.Infinite);
_receiveEventArgs = new SocketAsyncEventArgs();
_receiveEventArgs.SetBuffer(_buffer, 0, _buffer.Length);
Expand Down Expand Up @@ -174,7 +174,7 @@ internal void OnServiceQuery(Name serviceName)

private void StartReceive()
{
#if NETSTANDARD1_5
#if NETSTANDARD1_3
bool pending = _socket.ReceiveAsync(_receiveEventArgs);
if (!pending)
{
Expand All @@ -185,15 +185,15 @@ private void StartReceive()
#endif
}

#if NETSTANDARD1_5
#if NETSTANDARD1_3
private void OnReceive(object sender, SocketAsyncEventArgs args)
#else
private void OnReceive(IAsyncResult ar)
#endif
{
lock (this)
{
#if NETSTANDARD1_5
#if NETSTANDARD1_3
if (args.SocketError != SocketError.Success)
{
return;
Expand Down Expand Up @@ -695,7 +695,7 @@ private void ScheduleQueryTimer(int ms)
private Socket _socket;
private readonly int _index;
private readonly byte[] _buffer = new byte[9000];
#if NETSTANDARD1_5
#if NETSTANDARD1_3
private readonly SocketAsyncEventArgs _receiveEventArgs;
#endif
private readonly Dictionary<Name, ServiceInfo> _packetServiceInfos = new Dictionary<Name, ServiceInfo>();
Expand Down
4 changes: 2 additions & 2 deletions src/Tmds.MDns/project.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "0.5.0",
"version": "0.6.0",
"packOptions": {
"tags": [ "mdns", "avahi", "zeroconf", "rfc6762", "rfc6763" ],
"repository": {
Expand All @@ -13,7 +13,7 @@
"description": "This library allows to find services announced via multicast DNS (RFC6762 and RFC6763).",
"authors": [ "Tom Deseyn" ],
"frameworks": {
"netstandard1.5": {
"netstandard1.3": {
"dependencies": {
"System.Net.NetworkInformation": "4.1.0",
"System.Net.Sockets" : "4.1.0",
Expand Down

0 comments on commit aac4f08

Please sign in to comment.