[Date Prev][Date Next] [Chronological] [Thread] [Top]

Questing regarding random MAC address in uuid.c

 I stumbled across this when i was generating a UUID using uuid.c


	if (memcmp(eaddr, zero, sizeof(eaddr)) == 0) {
		/* XXX - who knows? */
		lutil_entropy( eaddr, sizeof(eaddr) );
		eaddr[0] |= 0x80; /* turn it into a multicast address */

	return eaddr;


the line in question is "eaddr[0] |= 0x80".
Shouldn't this be " eaddr[0] |= 0x01" to actually set the multicast bit ?