mirror of
https://github.com/reactos/reactos.git
synced 2024-11-18 21:13:52 +00:00
inet_addr returns address in network order, the IP address control wants it
in host order svn path=/trunk/; revision=20684
This commit is contained in:
parent
e05a2a9e6b
commit
216f6b8898
1 changed files with 8 additions and 4 deletions
|
@ -179,15 +179,18 @@ TCPIPPropertyPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
|||
while(pString->Next)
|
||||
pString = pString->Next;
|
||||
dwIPAddr = inet_addr(pString->IpAddress.String);
|
||||
SendDlgItemMessage(hwndDlg,IDC_IPADDR,IPM_SETADDRESS,0,dwIPAddr);
|
||||
SendDlgItemMessage(hwndDlg,IDC_IPADDR,IPM_SETADDRESS,0,
|
||||
ntohl(dwIPAddr));
|
||||
dwIPAddr = inet_addr(pString->IpMask.String);
|
||||
SendDlgItemMessage(hwndDlg,IDC_SUBNETMASK,IPM_SETADDRESS,0,dwIPAddr);
|
||||
SendDlgItemMessage(hwndDlg,IDC_SUBNETMASK,IPM_SETADDRESS,0,
|
||||
ntohl(dwIPAddr));
|
||||
|
||||
pString = &pInfo->GatewayList;
|
||||
while(pString->Next)
|
||||
pString = pString->Next;
|
||||
dwIPAddr = inet_addr(pString->IpAddress.String);
|
||||
SendDlgItemMessage(hwndDlg,IDC_DEFGATEWAY,IPM_SETADDRESS,0,dwIPAddr);
|
||||
SendDlgItemMessage(hwndDlg,IDC_DEFGATEWAY,IPM_SETADDRESS,0,
|
||||
ntohl(dwIPAddr));
|
||||
|
||||
}
|
||||
{
|
||||
|
@ -208,7 +211,8 @@ TCPIPPropertyPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
|||
while( NextDNSServer && StaticDNS < 2 ) {
|
||||
dwIPAddr = inet_addr(NextDNSServer);
|
||||
if( dwIPAddr != INADDR_NONE ) {
|
||||
SendDlgItemMessage(hwndDlg,IDC_DNS1 + StaticDNS,IPM_SETADDRESS,0,dwIPAddr);
|
||||
SendDlgItemMessage(hwndDlg,IDC_DNS1 + StaticDNS,
|
||||
IPM_SETADDRESS,0,ntohl(dwIPAddr));
|
||||
StaticDNS++;
|
||||
}
|
||||
NextDNSServer = strchr( pszDNS, ',' );
|
||||
|
|
Loading…
Reference in a new issue