[ros-diffs] [navaraf] 17013: Merge 16728 (ion) from trunk:
navaraf at svn.reactos.com
navaraf at svn.reactos.com
Wed Aug 3 19:13:10 CEST 2005
Merge 16728 (ion) from trunk:
- Don't try to get the length of a possibly empty string. This fixes
many menu applications (such as WinRAR). However I'm now getting a bug
due to a double-free. It seems a GDI Object is being freed twice. Can
anyone check this out please?
Modified: branches/ros-branch-0_2_7/reactos/lib/user32/windows/menu.c
_____
Modified: branches/ros-branch-0_2_7/reactos/lib/user32/windows/menu.c
--- branches/ros-branch-0_2_7/reactos/lib/user32/windows/menu.c
2005-08-03 17:10:45 UTC (rev 17012)
+++ branches/ros-branch-0_2_7/reactos/lib/user32/windows/menu.c
2005-08-03 17:13:04 UTC (rev 17013)
@@ -3771,8 +3771,11 @@
}
RtlCopyMemory(mii, &miiW, miiW.cbSize);
- mii->dwTypeData = AnsiBuffer;
- mii->cch = strlen(AnsiBuffer);
+ if (AnsiBuffer)
+ {
+ mii->dwTypeData = AnsiBuffer;
+ mii->cch = strlen(AnsiBuffer);
+ }
return TRUE;
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.reactos.org/pipermail/ros-diffs/attachments/20050803/cd6d92b8/attachment.html
More information about the Ros-diffs
mailing list