Alexandre Julliard : msvcrt: Fixed errno setting in malloc,
HeapAlloc doesn 't set last error.
Alexandre Julliard
julliard at wine.codeweavers.com
Fri Jul 27 07:34:37 CDT 2007
Module: wine
Branch: master
Commit: 00c81e9d9f6e72d3184540b4b1267dcbbfb86d4e
URL: http://source.winehq.org/git/wine.git/?a=commit;h=00c81e9d9f6e72d3184540b4b1267dcbbfb86d4e
Author: Alexandre Julliard <julliard at winehq.org>
Date: Fri Jul 27 12:18:15 2007 +0200
msvcrt: Fixed errno setting in malloc, HeapAlloc doesn't set last error.
---
dlls/msvcrt/heap.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/msvcrt/heap.c b/dlls/msvcrt/heap.c
index 0158435..ab6dd01 100644
--- a/dlls/msvcrt/heap.c
+++ b/dlls/msvcrt/heap.c
@@ -272,7 +272,7 @@ void* CDECL MSVCRT_malloc(MSVCRT_size_t size)
{
void *ret = HeapAlloc(GetProcessHeap(),0,size);
if (!ret)
- msvcrt_set_errno(GetLastError());
+ msvcrt_set_errno(MSVCRT_ENOMEM);
return ret;
}
More information about the wine-cvs
mailing list