msvcrt: Fixed errno setting in malloc, HeapAlloc doesn't set last error.

This commit is contained in:
Alexandre Julliard 2007-07-27 12:18:15 +02:00
parent b2acafad44
commit 00c81e9d9f
1 changed files with 1 additions and 1 deletions

View File

@ -272,7 +272,7 @@ void* CDECL MSVCRT_malloc(MSVCRT_size_t size)
{ {
void *ret = HeapAlloc(GetProcessHeap(),0,size); void *ret = HeapAlloc(GetProcessHeap(),0,size);
if (!ret) if (!ret)
msvcrt_set_errno(GetLastError()); msvcrt_set_errno(MSVCRT_ENOMEM);
return ret; return ret;
} }