SysReAllocStringLen nit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



ChangeLog
    SysReAllocStringLen is documented to segfault on NULL pointer.

Index: dlls/oleaut32/oleaut.c
===================================================================
RCS file: /var/cvs/wine/dlls/oleaut32/oleaut.c,v
retrieving revision 1.36
diff -u -r1.36 oleaut.c
--- dlls/oleaut32/oleaut.c	14 Nov 2003 21:01:15 -0000	1.36
+++ dlls/oleaut32/oleaut.c	25 Nov 2003 06:05:49 -0000
@@ -293,12 +293,6 @@
  */
 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));


-- 
Dimi.



[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux