Changeset 16251 in vbox for trunk/src/VBox/Main/linux/NetIfList-linux.cpp
- Timestamp:
- Jan 27, 2009 9:13:47 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/linux/NetIfList-linux.cpp
r15936 r16251 58 58 break; 59 59 } 60 /* Pick up some garbage from stack. */60 /* Generate UUID from name and MAC address. */ 61 61 RTUUID uuid; 62 Assert(sizeof(uuid) <= sizeof(Req)); 62 RTUuidClear(&uuid); 63 memcpy(&uuid, Req.ifr_name, RT_MIN(sizeof(Req.ifr_name), sizeof(uuid))); 64 uuid.Gen.u8ClockSeqHiAndReserved = (uuid.Gen.u8ClockSeqHiAndReserved & 0x3f) | 0x80; 65 uuid.Gen.u16TimeHiAndVersion = (uuid.Gen.u16TimeHiAndVersion & 0x0fff) | 0x4000; 63 66 memcpy(uuid.Gen.au8Node, &Req.ifr_hwaddr.sa_data, sizeof(uuid.Gen.au8Node)); 64 67 pInfo->Uuid = uuid; 68 65 69 memcpy(&pInfo->MACAddress, Req.ifr_hwaddr.sa_data, sizeof(pInfo->MACAddress)); 66 70
Note:
See TracChangeset
for help on using the changeset viewer.