[dbghelp] zero-terminate module name in minidump

Andrey Turkin andrey.turkin at gmail.com
Sat Apr 28 17:14:15 CDT 2007


Native does so, and VS debugger seems to be reading till null character.
-------------- next part --------------
--- wine-0.9.36-orig/dlls/dbghelp/minidump.c	2007-04-27 18:48:53.000000000 +0400
+++ wine-0.9.36/dlls/dbghelp/minidump.c	2007-04-29 02:09:04.390625000 +0400
@@ -476,7 +476,7 @@ static  void    dump_modules(struct dump
             mdModule.TimeDateStamp = dc->module[i].timestamp;
             mdModule.ModuleNameRva = dc->rva;
             ms->Length -= sizeof(WCHAR);
-            append(dc, ms, sizeof(ULONG) + ms->Length);
+            append(dc, ms, sizeof(ULONG) + ms->Length + sizeof(WCHAR));
             memset(&mdModule.VersionInfo, 0, sizeof(mdModule.VersionInfo)); /* FIXME */
             mdModule.CvRecord.DataSize = 0; /* FIXME */
             mdModule.CvRecord.Rva = 0; /* FIXME */


More information about the wine-patches mailing list