mirror of
https://github.com/reactos/reactos.git
synced 2025-06-12 14:18:29 +00:00
[DHCPCSVC]
Fix passing a 860B struct by value svn path=/trunk/; revision=53786
This commit is contained in:
parent
b41af56f6e
commit
ce3850ab01
1 changed files with 6 additions and 6 deletions
|
@ -190,13 +190,13 @@ void AdapterInit() {
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
InterfaceConnected(MIB_IFROW IfEntry)
|
InterfaceConnected(const PMIB_IFROW IfEntry)
|
||||||
{
|
{
|
||||||
if (IfEntry.dwOperStatus == IF_OPER_STATUS_CONNECTED ||
|
if (IfEntry->dwOperStatus == IF_OPER_STATUS_CONNECTED ||
|
||||||
IfEntry.dwOperStatus == IF_OPER_STATUS_OPERATIONAL)
|
IfEntry->dwOperStatus == IF_OPER_STATUS_OPERATIONAL)
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
DH_DbgPrint(MID_TRACE,("Interface %d is down\n", IfEntry.dwIndex));
|
DH_DbgPrint(MID_TRACE,("Interface %d is down\n", IfEntry->dwIndex));
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -241,7 +241,7 @@ DWORD WINAPI AdapterDiscoveryThread(LPVOID Context) {
|
||||||
if ((Adapter = AdapterFindByHardwareAddress(Table->table[i].bPhysAddr, Table->table[i].dwPhysAddrLen)))
|
if ((Adapter = AdapterFindByHardwareAddress(Table->table[i].bPhysAddr, Table->table[i].dwPhysAddrLen)))
|
||||||
{
|
{
|
||||||
/* This is an existing adapter */
|
/* This is an existing adapter */
|
||||||
if (InterfaceConnected(Table->table[i])) {
|
if (InterfaceConnected(&Table->table[i])) {
|
||||||
/* We're still active so we stay in the list */
|
/* We're still active so we stay in the list */
|
||||||
ifi = &Adapter->DhclientInfo;
|
ifi = &Adapter->DhclientInfo;
|
||||||
} else {
|
} else {
|
||||||
|
@ -259,7 +259,7 @@ DWORD WINAPI AdapterDiscoveryThread(LPVOID Context) {
|
||||||
|
|
||||||
Adapter = (DHCP_ADAPTER*) calloc( sizeof( DHCP_ADAPTER ) + Table->table[i].dwMtu, 1 );
|
Adapter = (DHCP_ADAPTER*) calloc( sizeof( DHCP_ADAPTER ) + Table->table[i].dwMtu, 1 );
|
||||||
|
|
||||||
if( Adapter && Table->table[i].dwType == MIB_IF_TYPE_ETHERNET && InterfaceConnected(Table->table[i])) {
|
if( Adapter && Table->table[i].dwType == MIB_IF_TYPE_ETHERNET && InterfaceConnected(&Table->table[i])) {
|
||||||
memcpy( &Adapter->IfMib, &Table->table[i],
|
memcpy( &Adapter->IfMib, &Table->table[i],
|
||||||
sizeof(Adapter->IfMib) );
|
sizeof(Adapter->IfMib) );
|
||||||
Adapter->DhclientInfo.client = &Adapter->DhclientState;
|
Adapter->DhclientInfo.client = &Adapter->DhclientState;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue