[PATCH 0/2] MR4669: Fix PDB reading.
Seen with PDB generated with "latest" MS compiler. The data here is likely to be in the same form of other hash structures we already handle. (eg has a first vector to describe present entries, and a second one to describe deleteid entries; we were incorrectly expecting an empty deleted vector... so just skip for now the deleted vector in winedump and dbghelp... this will probably end up with a more generic code for reloading such hash structures, but after code freeze). -- https://gitlab.winehq.org/wine/wine/-/merge_requests/4669
From: Eric Pouech <epouech(a)codeweavers.com> Signed-off-by: Eric Pouech <epouech(a)codeweavers.com> --- tools/winedump/pdb.c | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/tools/winedump/pdb.c b/tools/winedump/pdb.c index 552fa4d8da8..a11a0eb12d0 100644 --- a/tools/winedump/pdb.c +++ b/tools/winedump/pdb.c @@ -200,11 +200,7 @@ static unsigned get_stream_by_name(struct pdb_reader* reader, const char* name) /* bitfield: first dword is len (in dword), then data */ ok_bits = pdw; pdw += *ok_bits++ + 1; - if (*pdw++ != 0) - { - printf("unexpected value\n"); - return -1; - } + pdw += *pdw + 1; /* skip deleted vector */ for (i = 0; i < count; i++) { @@ -1194,11 +1190,7 @@ static void pdb_jg_dump_header_root(struct pdb_reader* reader) /* bitfield: first dword is len (in dword), then data */ ok_bits = pdw; pdw += *ok_bits++ + 1; - if (*pdw++ != 0) - { - printf("unexpected value\n"); - return; - } + pdw += *pdw + 1; /* skip deleted vector */ for (i = 0; i < count; i++) { @@ -1345,11 +1337,7 @@ static void pdb_ds_dump_header_root(struct pdb_reader* reader) /* bitfield: first dword is len (in dword), then data */ ok_bits = pdw; pdw += *ok_bits++ + 1; - if (*pdw++ != 0) - { - printf("unexpected value\n"); - return; - } + pdw += *pdw + 1; /* skip deleted vector */ for (i = 0; i < count; i++) { -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/4669
From: Eric Pouech <epouech(a)codeweavers.com> Signed-off-by: Eric Pouech <epouech(a)codeweavers.com> --- dlls/dbghelp/msc.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/dlls/dbghelp/msc.c b/dlls/dbghelp/msc.c index 5e699d54e2c..38a74a11850 100644 --- a/dlls/dbghelp/msc.c +++ b/dlls/dbghelp/msc.c @@ -3159,11 +3159,7 @@ static BOOL pdb_load_stream_name_table(struct pdb_file_info* pdb_file, const cha /* bitfield: first dword is len (in dword), then data */ ok_bits = pdw; pdw += *ok_bits++ + 1; - if (*pdw++ != 0) - { - FIXME("unexpected value\n"); - return FALSE; - } + pdw += *pdw + 1; /* skip deleted vector */ for (i = j = 0; i < count; i++) { -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/4669
participants (2)
-
Eric Pouech -
eric pouech (@epo)