aboutsummaryrefslogtreecommitdiff
path: root/libbutl/uuid-freebsd.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2020-06-18 14:09:59 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2020-06-18 14:09:59 +0200
commit18bed2c174362f76ddedf68bb700e8b2c817fcb5 (patch)
tree463c4a495386c9ec1869f4434367bfcfc43ea884 /libbutl/uuid-freebsd.cxx
parent639ff12af754d024a562925a52406ace0d3c673b (diff)
Complete NetBSD compatibility
Diffstat (limited to 'libbutl/uuid-freebsd.cxx')
-rw-r--r--libbutl/uuid-freebsd.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/libbutl/uuid-freebsd.cxx b/libbutl/uuid-freebsd.cxx
index 567c241..daf680b 100644
--- a/libbutl/uuid-freebsd.cxx
+++ b/libbutl/uuid-freebsd.cxx
@@ -31,7 +31,7 @@ namespace butl
//
// Specifically (and as of FreeBSD 11.2), we get a version 1 (MAC/time-
// based) UUID and it seems there is provision for getting the time in a
- // collision-safe:
+ // collision-safe manner:
//
// "According to the algorithm of generating time-based UUIDs, this will
// also force a new random clock sequence, thereby increasing the
@@ -43,6 +43,14 @@ namespace butl
// smart enough not to start return random UUIDs without a good source of
// randomness, at least not by default.
//
+ // When it comes to NetBSD, there is this HISTORY note in the uuidgen(2)
+ // man page:
+ //
+ // "It was changed to use version 4 UUIDs, i.e. randomly generated UUIDs,
+ // in NetBSD 8.0."
+ //
+ // And we will assume random NetBSD UUIDs are strong.
+ //
struct ::uuid d;
if (uuidgen (&d, 1) != 0)