Skip to content
Snippets Groups Projects
Commit 99bf92e3 authored by Dimitrie O. Paun's avatar Dimitrie O. Paun Committed by Alexandre Julliard
Browse files

SysReAllocStringLen is documented to segfault on NULL pointer.

parent d8aa8535
No related branches found
No related tags found
No related merge requests found
......@@ -293,12 +293,6 @@ BSTR WINAPI SysAllocStringLen(const OLECHAR *str, unsigned int len)
*/
int WINAPI SysReAllocStringLen(BSTR* old, const OLECHAR* str, unsigned int len)
{
/*
* Sanity check
*/
if (old==NULL)
return 0;
if (*old!=NULL) {
DWORD newbytelen = len*sizeof(WCHAR);
DWORD *ptr = HeapReAlloc(GetProcessHeap(),0,((DWORD*)*old)-1,newbytelen+sizeof(WCHAR)+sizeof(DWORD));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment