X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;ds=sidebyside;f=avahi-sharp%2FUtility.cs;h=a1d0a669ed66608069eafe0297f9533e2a0ad06e;hb=2aa610ca9e872c18937c298d1d52dea20702176d;hp=9081b011dc210a1e631ee5470021b9354f4e6221;hpb=d8fcf547a8c853ad6b2f92d2671a0389aa65b556;p=catta diff --git a/avahi-sharp/Utility.cs b/avahi-sharp/Utility.cs index 9081b01..a1d0a66 100644 --- a/avahi-sharp/Utility.cs +++ b/avahi-sharp/Utility.cs @@ -1,5 +1,3 @@ -/* $Id$ */ - /*** This file is part of avahi. @@ -45,7 +43,7 @@ namespace Avahi { if (ptr == IntPtr.Zero) return null; - + int len = strlen (ptr); byte[] bytes = new byte[len]; Marshal.Copy (ptr, bytes, 0, len); @@ -56,7 +54,7 @@ namespace Avahi { if (ptr == IntPtr.Zero) return null; - + string ret = PtrToString (ptr); Free (ptr); return ret; @@ -100,7 +98,7 @@ namespace Avahi public static IPAddress PtrToAddress (IntPtr ptr) { IPAddress address = null; - + if (ptr != IntPtr.Zero) { IntPtr buf = Stdlib.malloc (256); IntPtr addrPtr = avahi_address_snprint (buf, 256, ptr);