1
0
mirror of https://github.com/google/uuid.git synced 2024-11-21 17:16:42 +02:00

Add darkfeline's change to set ifname if no interface is found.

This commit is contained in:
Paul Borman 2019-02-27 15:05:49 -06:00
parent 9b3b1e0f5f
commit 0cd6bf5da1

View File

@ -48,6 +48,7 @@ func setNodeInterface(name string) bool {
// does not specify a specific interface generate a random Node ID
// (section 4.1.6)
if name == "" {
ifname = "random"
randomBits(nodeID[:])
return true
}