mirror of
https://github.com/solemnwarning/ipxwrapper
synced 2024-12-30 16:45:37 +01:00
Added workaround for Hamachi bug.
This commit is contained in:
parent
7a6c8e95da
commit
e82ffa87e2
@ -104,6 +104,17 @@ struct ipx_interface *get_interfaces(int ifnum) {
|
||||
|
||||
nnic->next = NULL;
|
||||
|
||||
/* Workaround for buggy versions of Hamachi that don't initialise
|
||||
* the interface hardware address correctly.
|
||||
*/
|
||||
|
||||
const unsigned char hamachi_bug[] = {0x7A, 0x79, 0x00, 0x00, 0x00, 0x00};
|
||||
|
||||
if(strcmp(ifptr->Description, "Hamachi Network Interface") == 0 && memcmp(nnic->ipx_node, hamachi_bug, 6) == 0) {
|
||||
log_printf("Invalid Hamachi interface detected, correcting node number");
|
||||
memcpy(nnic->ipx_node + 2, &(nnic->ipaddr), 4);
|
||||
}
|
||||
|
||||
if(got_rv && rv.primary) {
|
||||
/* Force primary flag set, insert at start of NIC list */
|
||||
nnic->next = nics;
|
||||
|
Loading…
x
Reference in New Issue
Block a user