diff --git a/source/nanoFramework.System.Net/Sockets/Socket.cs b/source/nanoFramework.System.Net/Sockets/Socket.cs index d65457d..1534dc6 100644 --- a/source/nanoFramework.System.Net/Sockets/Socket.cs +++ b/source/nanoFramework.System.Net/Sockets/Socket.cs @@ -19,7 +19,7 @@ public class Socket : IDisposable * The m_Handle field MUST be the first field in the Socket class; it is expected by * the SPOT.NET.SocketNative class. */ - // [FieldNoReflection] + // [FieldNoReflection] internal int m_Handle = -1; [Diagnostics.DebuggerBrowsable(Diagnostics.DebuggerBrowsableState.Never)] @@ -116,8 +116,6 @@ private EndPoint GetEndPoint(bool fLocal) throw new ObjectDisposedException(); } - EndPoint ep = null; - if (m_localEndPoint == null) { m_localEndPoint = new IPEndPoint(IPAddress.Any, 0); @@ -139,7 +137,7 @@ private EndPoint GetEndPoint(bool fLocal) m_localEndPoint = endPoint; } - return ep; + return endPoint; } ///