jscript: Fix possible NULL pointer access in heap_strdupW.
This commit is contained in:
parent
7e2cac2602
commit
6804ae26fb
|
@ -84,7 +84,8 @@ static inline LPWSTR heap_strdupW(LPCWSTR str)
|
|||
|
||||
size = (strlenW(str)+1)*sizeof(WCHAR);
|
||||
ret = heap_alloc(size);
|
||||
memcpy(ret, str, size);
|
||||
if(ret)
|
||||
memcpy(ret, str, size);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
|
Loading…
Reference in New Issue