Below is the list of changes that have just been committed into a local
6.0 repository of jas. When jas does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2007-11-05 16:17:23-05:00, jas@stripped +1 -0
Handle Ethernet devices > eth2.
storage/falcon/MACAddress.cpp@stripped, 2007-11-05 16:17:21-05:00, jas@stripped +8 -2
Check more ethernet devices for MAC address.
diff -Nrup a/storage/falcon/MACAddress.cpp b/storage/falcon/MACAddress.cpp
--- a/storage/falcon/MACAddress.cpp 2007-09-24 06:56:42 -04:00
+++ b/storage/falcon/MACAddress.cpp 2007-11-05 16:17:21 -05:00
@@ -44,6 +44,7 @@ static const char *devices [] = {
"eth0",
"eth1",
"eth2",
+ "eth6",
"xyzzy",
NULL
};
@@ -95,9 +96,14 @@ int MACAddress::getAddresses()
ifreq request;
- for (const char **device = devices; *device; ++device)
+ //for (const char **device = devices; *device; ++device)
+ for (int n = 0; n < 10; ++n)
{
- strncpy (request.ifr_name, *device, IFNAMSIZ);
+ //strncpy (request.ifr_name, *device, IFNAMSIZ);
+ char device[64];
+ sprintf(device, "eth%d", n);
+ strncpy (request.ifr_name, device, IFNAMSIZ);
+
if (ioctl (fd, SIOCGIFHWADDR, &request) == 0)
macAddresses [count++] = getAddress (6, (UCHAR*) request.ifr_hwaddr.sa_data);
}
| Thread |
|---|
| • bk commit into 6.0 tree (jas:1.2670) | Jim Starkey | 5 Nov |