Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
53ab4c53
Commit
53ab4c53
authored
Apr 22, 2022
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
include: Avoid Windows types in CodeView structure definitions.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6f04c33c
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
25 deletions
+24
-25
dbghelp_private.h
dlls/dbghelp/dbghelp_private.h
+2
-2
msc.c
dlls/dbghelp/msc.c
+16
-17
mscvpdb.h
include/wine/mscvpdb.h
+0
-0
debug.c
tools/winedump/debug.c
+6
-6
No files found.
dlls/dbghelp/dbghelp_private.h
View file @
53ab4c53
...
@@ -540,8 +540,8 @@ struct pdb_lookup
...
@@ -540,8 +540,8 @@ struct pdb_lookup
{
{
const
char
*
filename
;
const
char
*
filename
;
enum
pdb_kind
kind
;
enum
pdb_kind
kind
;
DWORD
age
;
unsigned
int
age
;
DWORD
timestamp
;
unsigned
int
timestamp
;
GUID
guid
;
GUID
guid
;
};
};
...
...
dlls/dbghelp/msc.c
View file @
53ab4c53
...
@@ -2761,7 +2761,7 @@ static void* pdb_jg_read(const struct PDB_JG_HEADER* pdb, const WORD* block_list
...
@@ -2761,7 +2761,7 @@ static void* pdb_jg_read(const struct PDB_JG_HEADER* pdb, const WORD* block_list
return
buffer
;
return
buffer
;
}
}
static
void
*
pdb_ds_read
(
const
struct
PDB_DS_HEADER
*
pdb
,
const
DWORD
*
block_list
,
static
void
*
pdb_ds_read
(
const
struct
PDB_DS_HEADER
*
pdb
,
const
UINT
*
block_list
,
int
size
)
int
size
)
{
{
int
i
,
num_blocks
;
int
i
,
num_blocks
;
...
@@ -2797,7 +2797,7 @@ static void* pdb_read_jg_file(const struct PDB_JG_HEADER* pdb,
...
@@ -2797,7 +2797,7 @@ static void* pdb_read_jg_file(const struct PDB_JG_HEADER* pdb,
static
void
*
pdb_read_ds_file
(
const
struct
PDB_DS_HEADER
*
pdb
,
static
void
*
pdb_read_ds_file
(
const
struct
PDB_DS_HEADER
*
pdb
,
const
struct
PDB_DS_TOC
*
toc
,
DWORD
file_nr
)
const
struct
PDB_DS_TOC
*
toc
,
DWORD
file_nr
)
{
{
const
DWORD
*
block_list
;
const
UINT
*
block_list
;
DWORD
i
;
DWORD
i
;
if
(
!
toc
||
file_nr
>=
toc
->
num_files
)
return
NULL
;
if
(
!
toc
||
file_nr
>=
toc
->
num_files
)
return
NULL
;
...
@@ -3069,7 +3069,7 @@ static BOOL pdb_init_type_parse(const struct msc_debug_info* msc_dbg,
...
@@ -3069,7 +3069,7 @@ static BOOL pdb_init_type_parse(const struct msc_debug_info* msc_dbg,
case
20040203
:
/* VC 8.0 */
case
20040203
:
/* VC 8.0 */
break
;
break
;
default:
default:
ERR
(
"-Unknown type info version %
l
d
\n
"
,
types
.
version
);
ERR
(
"-Unknown type info version %d
\n
"
,
types
.
version
);
return
FALSE
;
return
FALSE
;
}
}
...
@@ -3150,7 +3150,7 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
...
@@ -3150,7 +3150,7 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
case
19970604
:
/* VC 6.0 */
case
19970604
:
/* VC 6.0 */
break
;
break
;
default:
default:
ERR
(
"-Unknown root block version %
l
d
\n
"
,
root
->
Version
);
ERR
(
"-Unknown root block version %d
\n
"
,
root
->
Version
);
}
}
if
(
pdb_lookup
->
kind
!=
PDB_JG
)
if
(
pdb_lookup
->
kind
!=
PDB_JG
)
{
{
...
@@ -3162,12 +3162,12 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
...
@@ -3162,12 +3162,12 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
pdb_file
->
u
.
jg
.
timestamp
=
root
->
TimeDateStamp
;
pdb_file
->
u
.
jg
.
timestamp
=
root
->
TimeDateStamp
;
pdb_file
->
age
=
root
->
Age
;
pdb_file
->
age
=
root
->
Age
;
if
(
root
->
TimeDateStamp
==
pdb_lookup
->
timestamp
)
(
*
matched
)
++
;
if
(
root
->
TimeDateStamp
==
pdb_lookup
->
timestamp
)
(
*
matched
)
++
;
else
WARN
(
"Found %s, but wrong signature: %08
lx %08l
x
\n
"
,
else
WARN
(
"Found %s, but wrong signature: %08
x %08
x
\n
"
,
pdb_lookup
->
filename
,
root
->
TimeDateStamp
,
pdb_lookup
->
timestamp
);
pdb_lookup
->
filename
,
root
->
TimeDateStamp
,
pdb_lookup
->
timestamp
);
if
(
root
->
Age
==
pdb_lookup
->
age
)
(
*
matched
)
++
;
if
(
root
->
Age
==
pdb_lookup
->
age
)
(
*
matched
)
++
;
else
WARN
(
"Found %s, but wrong age: %08
lx %08l
x
\n
"
,
else
WARN
(
"Found %s, but wrong age: %08
x %08
x
\n
"
,
pdb_lookup
->
filename
,
root
->
Age
,
pdb_lookup
->
age
);
pdb_lookup
->
filename
,
root
->
Age
,
pdb_lookup
->
age
);
TRACE
(
"found JG for %s: age=%
lx timestamp=%l
x
\n
"
,
TRACE
(
"found JG for %s: age=%
x timestamp=%
x
\n
"
,
pdb_lookup
->
filename
,
root
->
Age
,
root
->
TimeDateStamp
);
pdb_lookup
->
filename
,
root
->
Age
,
root
->
TimeDateStamp
);
pdb_load_stream_name_table
(
pdb_file
,
&
root
->
names
[
0
],
root
->
cbNames
);
pdb_load_stream_name_table
(
pdb_file
,
&
root
->
names
[
0
],
root
->
cbNames
);
...
@@ -3179,8 +3179,7 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
...
@@ -3179,8 +3179,7 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
struct
PDB_DS_ROOT
*
root
;
struct
PDB_DS_ROOT
*
root
;
pdb_file
->
u
.
ds
.
toc
=
pdb_file
->
u
.
ds
.
toc
=
pdb_ds_read
(
pdb
,
pdb_ds_read
(
pdb
,
(
const
UINT
*
)((
const
char
*
)
pdb
+
pdb
->
toc_page
*
pdb
->
block_size
),
(
const
DWORD
*
)((
const
char
*
)
pdb
+
pdb
->
toc_page
*
pdb
->
block_size
),
pdb
->
toc_size
);
pdb
->
toc_size
);
root
=
pdb_read_ds_file
(
pdb
,
pdb_file
->
u
.
ds
.
toc
,
1
);
root
=
pdb_read_ds_file
(
pdb
,
pdb_file
->
u
.
ds
.
toc
,
1
);
if
(
!
root
)
if
(
!
root
)
...
@@ -3193,7 +3192,7 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
...
@@ -3193,7 +3192,7 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
case
20000404
:
case
20000404
:
break
;
break
;
default:
default:
ERR
(
"-Unknown root block version %
ld
\n
"
,
root
->
Version
);
ERR
(
"-Unknown root block version %
u
\n
"
,
root
->
Version
);
}
}
pdb_file
->
kind
=
PDB_DS
;
pdb_file
->
kind
=
PDB_DS
;
pdb_file
->
u
.
ds
.
guid
=
root
->
guid
;
pdb_file
->
u
.
ds
.
guid
=
root
->
guid
;
...
@@ -3203,9 +3202,9 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
...
@@ -3203,9 +3202,9 @@ static BOOL pdb_init(const struct pdb_lookup* pdb_lookup, struct pdb_file_info*
pdb_lookup
->
filename
,
debugstr_guid
(
&
root
->
guid
),
pdb_lookup
->
filename
,
debugstr_guid
(
&
root
->
guid
),
debugstr_guid
(
&
pdb_lookup
->
guid
));
debugstr_guid
(
&
pdb_lookup
->
guid
));
if
(
root
->
Age
==
pdb_lookup
->
age
)
(
*
matched
)
++
;
if
(
root
->
Age
==
pdb_lookup
->
age
)
(
*
matched
)
++
;
else
WARN
(
"Found %s, but wrong age: %08
lx %08l
x
\n
"
,
else
WARN
(
"Found %s, but wrong age: %08
x %08
x
\n
"
,
pdb_lookup
->
filename
,
root
->
Age
,
pdb_lookup
->
age
);
pdb_lookup
->
filename
,
root
->
Age
,
pdb_lookup
->
age
);
TRACE
(
"found DS for %s: age=%
l
x guid=%s
\n
"
,
TRACE
(
"found DS for %s: age=%x guid=%s
\n
"
,
pdb_lookup
->
filename
,
root
->
Age
,
debugstr_guid
(
&
root
->
guid
));
pdb_lookup
->
filename
,
root
->
Age
,
debugstr_guid
(
&
root
->
guid
));
pdb_load_stream_name_table
(
pdb_file
,
&
root
->
names
[
0
],
root
->
cbNames
);
pdb_load_stream_name_table
(
pdb_file
,
&
root
->
names
[
0
],
root
->
cbNames
);
...
@@ -3284,7 +3283,7 @@ static void pdb_process_symbol_imports(const struct process* pcs,
...
@@ -3284,7 +3283,7 @@ static void pdb_process_symbol_imports(const struct process* pcs,
imp_pdb_lookup
.
kind
=
PDB_JG
;
imp_pdb_lookup
.
kind
=
PDB_JG
;
imp_pdb_lookup
.
timestamp
=
imp
->
TimeDateStamp
;
imp_pdb_lookup
.
timestamp
=
imp
->
TimeDateStamp
;
imp_pdb_lookup
.
age
=
imp
->
Age
;
imp_pdb_lookup
.
age
=
imp
->
Age
;
TRACE
(
"got for %s: age=%
lu ts=%l
x
\n
"
,
TRACE
(
"got for %s: age=%
u ts=%
x
\n
"
,
imp
->
filename
,
imp
->
Age
,
imp
->
TimeDateStamp
);
imp
->
filename
,
imp
->
Age
,
imp
->
TimeDateStamp
);
pdb_process_internal
(
pcs
,
msc_dbg
,
&
imp_pdb_lookup
,
pdb_module_info
,
i
);
pdb_process_internal
(
pcs
,
msc_dbg
,
&
imp_pdb_lookup
,
pdb_module_info
,
i
);
}
}
...
@@ -3359,7 +3358,7 @@ static BOOL pdb_process_internal(const struct process* pcs,
...
@@ -3359,7 +3358,7 @@ static BOOL pdb_process_internal(const struct process* pcs,
case
19990903
:
case
19990903
:
break
;
break
;
default:
default:
ERR
(
"-Unknown symbol info version %
ld %08l
x
\n
"
,
ERR
(
"-Unknown symbol info version %
u %08
x
\n
"
,
symbols
.
version
,
symbols
.
version
);
symbols
.
version
,
symbols
.
version
);
}
}
...
@@ -3377,7 +3376,7 @@ static BOOL pdb_process_internal(const struct process* pcs,
...
@@ -3377,7 +3376,7 @@ static BOOL pdb_process_internal(const struct process* pcs,
pdb_file
->
fpoext_stream
=
psi
->
FPO_EXT
;
pdb_file
->
fpoext_stream
=
psi
->
FPO_EXT
;
break
;
break
;
default:
default:
FIXME
(
"Unknown PDB_STREAM_INDEXES size (%
ld
)
\n
"
,
symbols
.
stream_index_size
);
FIXME
(
"Unknown PDB_STREAM_INDEXES size (%
u
)
\n
"
,
symbols
.
stream_index_size
);
break
;
break
;
}
}
files_image
=
pdb_read_strings
(
pdb_file
);
files_image
=
pdb_read_strings
(
pdb_file
);
...
@@ -3817,7 +3816,7 @@ BOOL pdb_virtual_unwind(struct cpu_stack_walk *csw, DWORD_PTR ip,
...
@@ -3817,7 +3816,7 @@ BOOL pdb_virtual_unwind(struct cpu_stack_walk *csw, DWORD_PTR ip,
{
{
if
(
fpoext
[
i
].
start
<=
ip
&&
ip
<
fpoext
[
i
].
start
+
fpoext
[
i
].
func_size
)
if
(
fpoext
[
i
].
start
<=
ip
&&
ip
<
fpoext
[
i
].
start
+
fpoext
[
i
].
func_size
)
{
{
TRACE
(
"
\t
%08
lx %08lx %8lx %8lx %4lx %4x %4x %08l
x %s
\n
"
,
TRACE
(
"
\t
%08
x %08x %8x %8x %4x %4x %4x %08
x %s
\n
"
,
fpoext
[
i
].
start
,
fpoext
[
i
].
func_size
,
fpoext
[
i
].
locals_size
,
fpoext
[
i
].
start
,
fpoext
[
i
].
func_size
,
fpoext
[
i
].
locals_size
,
fpoext
[
i
].
params_size
,
fpoext
[
i
].
maxstack_size
,
fpoext
[
i
].
prolog_size
,
fpoext
[
i
].
params_size
,
fpoext
[
i
].
maxstack_size
,
fpoext
[
i
].
prolog_size
,
fpoext
[
i
].
savedregs_size
,
fpoext
[
i
].
flags
,
fpoext
[
i
].
savedregs_size
,
fpoext
[
i
].
flags
,
...
@@ -3951,7 +3950,7 @@ static BOOL codeview_process_info(const struct process* pcs,
...
@@ -3951,7 +3950,7 @@ static BOOL codeview_process_info(const struct process* pcs,
{
{
const
OMFSignatureRSDS
*
rsds
=
(
const
OMFSignatureRSDS
*
)
msc_dbg
->
root
;
const
OMFSignatureRSDS
*
rsds
=
(
const
OMFSignatureRSDS
*
)
msc_dbg
->
root
;
TRACE
(
"Got RSDS type of PDB file: guid=%s age=%08
l
x name=%s
\n
"
,
TRACE
(
"Got RSDS type of PDB file: guid=%s age=%08x name=%s
\n
"
,
wine_dbgstr_guid
(
&
rsds
->
guid
),
rsds
->
age
,
rsds
->
name
);
wine_dbgstr_guid
(
&
rsds
->
guid
),
rsds
->
age
,
rsds
->
name
);
pdb_lookup
.
filename
=
rsds
->
name
;
pdb_lookup
.
filename
=
rsds
->
name
;
pdb_lookup
.
kind
=
PDB_DS
;
pdb_lookup
.
kind
=
PDB_DS
;
...
...
include/wine/mscvpdb.h
View file @
53ab4c53
This diff is collapsed.
Click to expand it.
tools/winedump/debug.c
View file @
53ab4c53
...
@@ -211,8 +211,8 @@ static BOOL dump_cv_sst_seg_map(const OMFDirEntry* omfde)
...
@@ -211,8 +211,8 @@ static BOOL dump_cv_sst_seg_map(const OMFDirEntry* omfde)
printf
(
" frame: %u
\n
"
,
segMapDesc
[
i
].
frame
);
printf
(
" frame: %u
\n
"
,
segMapDesc
[
i
].
frame
);
printf
(
" iSegName: %u
\n
"
,
segMapDesc
[
i
].
iSegName
);
printf
(
" iSegName: %u
\n
"
,
segMapDesc
[
i
].
iSegName
);
printf
(
" iClassName: %u
\n
"
,
segMapDesc
[
i
].
iClassName
);
printf
(
" iClassName: %u
\n
"
,
segMapDesc
[
i
].
iClassName
);
printf
(
" offset: %
l
u
\n
"
,
segMapDesc
[
i
].
offset
);
printf
(
" offset: %u
\n
"
,
segMapDesc
[
i
].
offset
);
printf
(
" cbSeg: %
l
u
\n
"
,
segMapDesc
[
i
].
cbSeg
);
printf
(
" cbSeg: %u
\n
"
,
segMapDesc
[
i
].
cbSeg
);
}
}
return
TRUE
;
return
TRUE
;
...
@@ -244,7 +244,7 @@ static BOOL dump_cv_sst_src_module(const OMFDirEntry* omfde)
...
@@ -244,7 +244,7 @@ static BOOL dump_cv_sst_src_module(const OMFDirEntry* omfde)
sourceModule
->
cFile
,
sourceModule
->
cSeg
);
sourceModule
->
cFile
,
sourceModule
->
cSeg
);
for
(
i
=
0
;
i
<
sourceModule
->
cFile
;
i
++
)
for
(
i
=
0
;
i
<
sourceModule
->
cFile
;
i
++
)
{
{
printf
(
" File #%2d begins at an offset of 0x%
l
x in this section
\n
"
,
printf
(
" File #%2d begins at an offset of 0x%x in this section
\n
"
,
i
+
1
,
sourceModule
->
baseSrcFile
[
i
]);
i
+
1
,
sourceModule
->
baseSrcFile
[
i
]);
}
}
...
@@ -285,7 +285,7 @@ static BOOL dump_cv_sst_src_module(const OMFDirEntry* omfde)
...
@@ -285,7 +285,7 @@ static BOOL dump_cv_sst_src_module(const OMFDirEntry* omfde)
for
(
i
=
0
;
i
<
sourceFile
->
cSeg
;
i
++
)
for
(
i
=
0
;
i
<
sourceFile
->
cSeg
;
i
++
)
{
{
printf
(
" Segment #%2d start = 0x%lx, end = 0x%lx, offset = 0x%
l
x
\n
"
,
printf
(
" Segment #%2d start = 0x%lx, end = 0x%lx, offset = 0x%x
\n
"
,
i
+
1
,
seg_info_dw
[
i
*
2
],
seg_info_dw
[(
i
*
2
)
+
1
],
sourceFile
->
baseSrcLn
[
i
]);
i
+
1
,
seg_info_dw
[
i
*
2
],
seg_info_dw
[(
i
*
2
)
+
1
],
sourceFile
->
baseSrcLn
[
i
]);
}
}
/* add file name length */
/* add file name length */
...
@@ -402,7 +402,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len)
...
@@ -402,7 +402,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len)
const
CODEVIEW_PDB_DATA
*
pdb_data
;
const
CODEVIEW_PDB_DATA
*
pdb_data
;
pdb_data
=
cv_base
;
pdb_data
=
cv_base
;
printf
(
" Filepos: 0x%08
l
X
\n
"
,
pdb_data
->
filepos
);
printf
(
" Filepos: 0x%08X
\n
"
,
pdb_data
->
filepos
);
printf
(
" TimeStamp: %08X (%s)
\n
"
,
printf
(
" TimeStamp: %08X (%s)
\n
"
,
pdb_data
->
timestamp
,
get_time_str
(
pdb_data
->
timestamp
));
pdb_data
->
timestamp
,
get_time_str
(
pdb_data
->
timestamp
));
printf
(
" Age: %08X
\n
"
,
pdb_data
->
age
);
printf
(
" Age: %08X
\n
"
,
pdb_data
->
age
);
...
@@ -428,7 +428,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len)
...
@@ -428,7 +428,7 @@ static void dump_codeview_headers(unsigned long base, unsigned long len)
sig
=
cv_base
;
sig
=
cv_base
;
printf
(
" Filepos: 0x%08
l
X
\n
"
,
sig
->
filepos
);
printf
(
" Filepos: 0x%08X
\n
"
,
sig
->
filepos
);
dirHeader
=
PRD
(
Offset
(
cv_base
)
+
sig
->
filepos
,
sizeof
(
OMFDirHeader
));
dirHeader
=
PRD
(
Offset
(
cv_base
)
+
sig
->
filepos
,
sizeof
(
OMFDirHeader
));
if
(
!
dirHeader
)
{
printf
(
"Can't get debug header, aborting
\n
"
);
return
;}
if
(
!
dirHeader
)
{
printf
(
"Can't get debug header, aborting
\n
"
);
return
;}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment