Commit 713ca17b authored by Mike McCormack's avatar Mike McCormack Committed by Alexandre Julliard

Fix some gcc 4.0 warnings.

parent 420d7a82
......@@ -86,7 +86,7 @@ static BOOL TOOLHELP_Thread32Next( HANDLE handle, LPTHREADENTRY32 lpte, BOOL fir
if (lpte->dwSize < sizeof(THREADENTRY32))
{
SetLastError( ERROR_INSUFFICIENT_BUFFER );
ERR("Result buffer too small (req: %d, was: %ld)\n", sizeof(THREADENTRY32), lpte->dwSize);
ERR("Result buffer too small (%ld)\n", lpte->dwSize);
return FALSE;
}
SERVER_START_REQ( next_thread )
......@@ -138,26 +138,16 @@ static BOOL TOOLHELP_Process32Next( HANDLE handle, LPPROCESSENTRY32W lppe, BOOL
{
BOOL ret;
WCHAR exe[MAX_PATH-1];
DWORD len;
DWORD len, sz;
if (unicode)
{
if (lppe->dwSize < sizeof(PROCESSENTRY32W))
{
SetLastError( ERROR_INSUFFICIENT_BUFFER );
ERR("Result buffer too small (req: %d, was: %ld)\n", sizeof(PROCESSENTRY32W), lppe->dwSize);
return FALSE;
}
}
else
sz = unicode ? sizeof(PROCESSENTRY32W) : sizeof(PROCESSENTRY32);
if (lppe->dwSize < sz)
{
if (lppe->dwSize < sizeof(PROCESSENTRY32))
{
SetLastError( ERROR_INSUFFICIENT_BUFFER );
ERR("Result buffer too small (req: %d, was: %ld)\n", sizeof(PROCESSENTRY32), lppe->dwSize);
return FALSE;
}
SetLastError( ERROR_INSUFFICIENT_BUFFER );
ERR("Result buffer too small (req: %ld, was: %ld)\n", sz, lppe->dwSize);
return FALSE;
}
SERVER_START_REQ( next_process )
{
req->handle = handle;
......
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