[commit] r2356 - NetBSD uses uuid_generate() instead of uuidgen()

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[commit] r2356 - NetBSD uses uuid_generate() instead of uuidgen()

commits-3
 
Author: piumarta
Date: 2011-01-23 01:56:18 -0800 (Sun, 23 Jan 2011)
New Revision: 2356

Modified:
   trunk/platforms/unix/ChangeLog
   trunk/platforms/unix/plugins/UUIDPlugin/sqUnixUUID.c
Log:
NetBSD uses uuid_generate() instead of uuidgen()

Modified: trunk/platforms/unix/ChangeLog
===================================================================
--- trunk/platforms/unix/ChangeLog 2011-01-23 09:41:21 UTC (rev 2355)
+++ trunk/platforms/unix/ChangeLog 2011-01-23 09:56:18 UTC (rev 2356)
@@ -1,5 +1,8 @@
 2011-01-23  Ian Piumarta  <com -dot- gmail -at- piumarta (backwards)>
 
+ * plugins/UUIDPlugin/sqUnixUUID.c (MakeUUID): NetBSD has
+ uuid_generate() not uuidgen().
+
  * vm-display-X11/config.cmake: Use configured variable
  X11_Xrender_LIB in link libraries list.
 

Modified: trunk/platforms/unix/plugins/UUIDPlugin/sqUnixUUID.c
===================================================================
--- trunk/platforms/unix/plugins/UUIDPlugin/sqUnixUUID.c 2011-01-23 09:41:21 UTC (rev 2355)
+++ trunk/platforms/unix/plugins/UUIDPlugin/sqUnixUUID.c 2011-01-23 09:56:18 UTC (rev 2356)
@@ -1,4 +1,10 @@
 #include "config.h"
+
+#if defined(__NetBSD__)
+# include <sys/types.h>
+# include <sys/uuid.h>
+#endif
+
 #include <uuid.h>
 #include "sq.h"
 
@@ -15,7 +21,13 @@
 int MakeUUID(char *location)
 {
   uuid_t uuid;
+
+#if defined(__NetBSD__)
+  uuidgen(&uuid, 1);
+#else
   uuid_generate(uuid);
+#endif
+
   memcpy((void *)location, (void *)&uuid, sizeof(uuid));
   return 1;
 }

Reply | Threaded
Open this post in threaded view
|

Re: [commit] r2356 - NetBSD uses uuid_generate() instead of uuidgen()

Pierce Ng-2
 
On Sun, Jan 23, 2011 at 01:56:19AM -0800, [hidden email] wrote:
> NetBSD uses uuid_generate() instead of uuidgen()

The same for FreeBSD, I believe.

Reply | Threaded
Open this post in threaded view
|

Re: [commit] r2356 - NetBSD uses uuid_generate() instead of uuidgen()

Aleksej Saushev-2
 
Pierce Ng <[hidden email]> writes:

> On Sun, Jan 23, 2011 at 01:56:19AM -0800, [hidden email] wrote:
>> NetBSD uses uuid_generate() instead of uuidgen()
>
> The same for FreeBSD, I believe.

Probably, but I don't have FreeBSD system to test it.

(Commit message is wrong, BTW.)


--
HE CE3OH...