winspool: Test for failure using correct size.
This commit is contained in:
parent
7251e91d4d
commit
09401dd4b1
|
@ -4447,7 +4447,7 @@ BOOL WINAPI GetPrinterDriverW(HANDLE hPrinter, LPWSTR pEnvironment,
|
||||||
|
|
||||||
if(pcbNeeded) *pcbNeeded = size + needed;
|
if(pcbNeeded) *pcbNeeded = size + needed;
|
||||||
TRACE("buffer space %d required %d\n", cbBuf, size + needed);
|
TRACE("buffer space %d required %d\n", cbBuf, size + needed);
|
||||||
if(cbBuf >= needed) return TRUE;
|
if(cbBuf >= size + needed) return TRUE;
|
||||||
SetLastError(ERROR_INSUFFICIENT_BUFFER);
|
SetLastError(ERROR_INSUFFICIENT_BUFFER);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue