[PATCH 1/3] msvcrt: Lock the heap in _callnewh
Piotr Caban
piotr.caban at gmail.com
Fri Nov 6 04:49:39 CST 2015
On 11/06/15 11:28, Martin Storsjo wrote:
> int CDECL _callnewh(MSVCRT_size_t size)
> {
> + int ret = 0;
> + LOCK_HEAP;
> if(MSVCRT_new_handler)
> - (*MSVCRT_new_handler)(size);
> - return 0;
> + ret = (*MSVCRT_new_handler)(size);
> + UNLOCK_HEAP;
> + return ret;
> }
It doesn't make sense to lock heap cs in this case. Native is not doing
it (at least in case of msvcp90.dll). The return value change looks
almost correct - the function only returns 0 or 1.
Thanks,
Piotr
More information about the wine-devel
mailing list