Browse Source

Minor improvements

nxrighthere 7 years ago
parent
commit
d29cafa649
2 changed files with 3 additions and 3 deletions
  1. 2 2
      Source/Managed/ENet.cs
  2. 1 1
      Source/Native/enet.h

+ 2 - 2
Source/Managed/ENet.cs

@@ -89,7 +89,7 @@ namespace ENet {
 
 
 	internal static class ArrayPool {
 	internal static class ArrayPool {
 		[ThreadStatic]
 		[ThreadStatic]
-		private static byte[] buffer = null;
+		private static byte[] buffer;
 
 
 		public static byte[] GetBuffer() {
 		public static byte[] GetBuffer() {
 			if (buffer == null)
 			if (buffer == null)
@@ -847,4 +847,4 @@ namespace ENet {
 		[DllImport(nativeLibrary, CallingConvention = CallingConvention.Cdecl)]
 		[DllImport(nativeLibrary, CallingConvention = CallingConvention.Cdecl)]
 		internal static extern void enet_peer_reset(IntPtr peer);
 		internal static extern void enet_peer_reset(IntPtr peer);
 	}
 	}
-}
+}

+ 1 - 1
Source/Native/enet.h

@@ -131,7 +131,7 @@
     #include <sys/ioctl.h>
     #include <sys/ioctl.h>
     #include <sys/time.h>
     #include <sys/time.h>
     #include <sys/socket.h>
     #include <sys/socket.h>
-    #include <sys/poll.h>
+    #include <poll.h>
     #include <arpa/inet.h>
     #include <arpa/inet.h>
     #include <netinet/in.h>
     #include <netinet/in.h>
     #include <netinet/tcp.h>
     #include <netinet/tcp.h>