[ros-diffs] [royce] 17843: zero out the struct and disable code that has no connection with reality - I'm thinking MIIM_STRING should be removed from flags also, but I have not tested with that change.

royce at svn.reactos.com royce at svn.reactos.com
Wed Sep 14 01:04:36 CEST 2005


zero out the struct and disable code that has no connection with reality
- I'm thinking MIIM_STRING should be removed from flags also, but I have
not tested with that change.
Modified: trunk/reactos/lib/user32/windows/menu.c
  _____  

Modified: trunk/reactos/lib/user32/windows/menu.c
--- trunk/reactos/lib/user32/windows/menu.c	2005-09-13 20:26:57 UTC
(rev 17842)
+++ trunk/reactos/lib/user32/windows/menu.c	2005-09-13 23:04:32 UTC
(rev 17843)
@@ -4415,9 +4415,9 @@

   LPCWSTR lpNewItem)
 {
   MENUITEMINFOW mii;
+  memset ( &mii, 0, sizeof(mii) );
   mii.cbSize = sizeof(MENUITEMINFOW);
   mii.fMask = MIIM_FTYPE | MIIM_STRING | MIIM_STATE;
-  mii.fType = 0;
   mii.fState = MFS_ENABLED;
 
   UNIMPLEMENTED;
@@ -4442,10 +4442,10 @@
   }
   else
   {
-    if(mii.dwTypeData != NULL)
+    /*if(mii.dwTypeData != NULL)
     {
       HeapFree(GetProcessHeap(),0, mii.dwTypeData);
-    }
+    }*/
     if (*lpNewItem == '\b')
     {
        mii.fType |= MF_HELP;
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-diffs/attachments/20050914/8f79288f/attachment.html


More information about the Ros-diffs mailing list