mirror of
https://github.com/roytam1/UXP.git
synced 2026-05-26 13:58:49 +00:00
Issue #2925 followup - Restore previous GlobalFree behavior from before SCTP upgrade in sctp_bsd_addr.c
This commit is contained in:
@@ -336,7 +336,8 @@ sctp_init_ifns_for_vrf(int vrfid)
|
|||||||
/* Get actual adapter information */
|
/* Get actual adapter information */
|
||||||
if ((Err = GetAdaptersAddresses(AF_INET, 0, NULL, pAdapterAddrs, &AdapterAddrsSize)) != ERROR_SUCCESS) {
|
if ((Err = GetAdaptersAddresses(AF_INET, 0, NULL, pAdapterAddrs, &AdapterAddrsSize)) != ERROR_SUCCESS) {
|
||||||
SCTP_PRINTF("GetAdaptersV4Addresses() failed with error code %d\n", Err);
|
SCTP_PRINTF("GetAdaptersV4Addresses() failed with error code %d\n", Err);
|
||||||
FREE(pAdapterAddrs);
|
if (pAdapterAddrs)
|
||||||
|
GlobalFree(pAdapterAddrs);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
/* Enumerate through each returned adapter and save its information */
|
/* Enumerate through each returned adapter and save its information */
|
||||||
@@ -361,7 +362,8 @@ sctp_init_ifns_for_vrf(int vrfid)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FREE(pAdapterAddrs);
|
if (pAdapterAddrs)
|
||||||
|
GlobalFree(pAdapterAddrs);
|
||||||
#endif
|
#endif
|
||||||
#ifdef INET6
|
#ifdef INET6
|
||||||
AdapterAddrsSize = 0;
|
AdapterAddrsSize = 0;
|
||||||
@@ -381,7 +383,8 @@ sctp_init_ifns_for_vrf(int vrfid)
|
|||||||
/* Get actual adapter information */
|
/* Get actual adapter information */
|
||||||
if ((Err = GetAdaptersAddresses(AF_INET6, 0, NULL, pAdapterAddrs, &AdapterAddrsSize)) != ERROR_SUCCESS) {
|
if ((Err = GetAdaptersAddresses(AF_INET6, 0, NULL, pAdapterAddrs, &AdapterAddrsSize)) != ERROR_SUCCESS) {
|
||||||
SCTP_PRINTF("GetAdaptersV6Addresses() failed with error code %d\n", Err);
|
SCTP_PRINTF("GetAdaptersV6Addresses() failed with error code %d\n", Err);
|
||||||
FREE(pAdapterAddrs);
|
if (pAdapterAddrs)
|
||||||
|
GlobalFree(pAdapterAddrs);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
/* Enumerate through each returned adapter and save its information */
|
/* Enumerate through each returned adapter and save its information */
|
||||||
@@ -403,7 +406,8 @@ sctp_init_ifns_for_vrf(int vrfid)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FREE(pAdapterAddrs);
|
if (pAdapterAddrs)
|
||||||
|
GlobalFree(pAdapterAddrs);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
#elif defined(__Userspace__)
|
#elif defined(__Userspace__)
|
||||||
|
|||||||
Reference in New Issue
Block a user