Commit d9c1fc33 authored by François Gouget's avatar François Gouget Committed by Alexandre Julliard

Storing an IP address in a signed int results in bugs if it starts

with >=128.
parent c59655ed
......@@ -347,7 +347,8 @@ IPADDRESS_SetAddress (HWND hwnd, WPARAM wParam, LPARAM lParam)
HDC hdc;
LPIP_SUBCLASS_INFO lpipsi=(LPIP_SUBCLASS_INFO)
GetPropA ((HWND)hwnd, IP_SUBCLASS_PROP);
int i,ip_address,value;
int i,value;
DWORD ip_address;
char buf[20];
TRACE("\n");
......@@ -361,7 +362,7 @@ IPADDRESS_SetAddress (HWND hwnd, WPARAM wParam, LPARAM lParam)
SetWindowTextA (lpipsi->hwndIP[i],buf);
IPADDRESS_SendNotify (hwnd, EN_CHANGE);
}
ip_address/=256;
ip_address= ip_address >> 8;
}
hdc = GetDC (hwnd); /* & send notifications */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment