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
ddf57d26
Commit
ddf57d26
authored
Jul 21, 2015
by
André Hentschel
Committed by
Alexandre Julliard
Jul 22, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winedump: Dump load config when available.
parent
b4b65d82
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
49 additions
and
1 deletion
+49
-1
main.c
tools/winedump/main.c
+1
-1
pe.c
tools/winedump/pe.c
+48
-0
No files found.
tools/winedump/main.c
View file @
ddf57d26
...
@@ -228,7 +228,7 @@ static const struct my_option option_table[] = {
...
@@ -228,7 +228,7 @@ static const struct my_option option_table[] = {
{
"-C"
,
DUMP
,
0
,
do_symdmngl
,
"-C Turn on symbol demangling"
},
{
"-C"
,
DUMP
,
0
,
do_symdmngl
,
"-C Turn on symbol demangling"
},
{
"-f"
,
DUMP
,
0
,
do_dumphead
,
"-f Dump file header information"
},
{
"-f"
,
DUMP
,
0
,
do_dumphead
,
"-f Dump file header information"
},
{
"-G"
,
DUMP
,
0
,
do_rawdebug
,
"-G Dump raw debug information"
},
{
"-G"
,
DUMP
,
0
,
do_rawdebug
,
"-G Dump raw debug information"
},
{
"-j"
,
DUMP
,
1
,
do_dumpsect
,
"-j <sect_name> Dump only the content of section 'sect_name' (import, export, debug, resource, tls, clr, reloc, except)"
},
{
"-j"
,
DUMP
,
1
,
do_dumpsect
,
"-j <sect_name> Dump only the content of section 'sect_name' (import, export, debug, resource, tls,
loadcfg,
clr, reloc, except)"
},
{
"-t"
,
DUMP
,
0
,
do_symtable
,
"-t Dump symbol table"
},
{
"-t"
,
DUMP
,
0
,
do_symtable
,
"-t Dump symbol table"
},
{
"-x"
,
DUMP
,
0
,
do_dumpall
,
"-x Dump everything"
},
{
"-x"
,
DUMP
,
0
,
do_dumpall
,
"-x Dump everything"
},
{
NULL
,
NONE
,
0
,
NULL
,
NULL
}
{
NULL
,
NONE
,
0
,
NULL
,
NULL
}
...
...
tools/winedump/pe.c
View file @
ddf57d26
...
@@ -1266,6 +1266,52 @@ static void dump_dir_imported_functions(void)
...
@@ -1266,6 +1266,52 @@ static void dump_dir_imported_functions(void)
printf
(
"
\n
"
);
printf
(
"
\n
"
);
}
}
static
void
dump_dir_loadconfig
(
void
)
{
const
IMAGE_LOAD_CONFIG_DIRECTORY32
*
loadcfg32
=
get_dir
(
IMAGE_DIRECTORY_ENTRY_LOAD_CONFIG
);
const
IMAGE_LOAD_CONFIG_DIRECTORY64
*
loadcfg64
=
(
void
*
)
loadcfg32
;
if
(
!
loadcfg32
)
return
;
printf
(
"Loadconfig
\n
"
);
print_dword
(
"Size"
,
loadcfg32
->
Size
);
print_dword
(
"TimeDateStamp"
,
loadcfg32
->
TimeDateStamp
);
print_word
(
"MajorVersion"
,
loadcfg32
->
MajorVersion
);
print_word
(
"MinorVersion"
,
loadcfg32
->
MinorVersion
);
print_dword
(
"GlobalFlagsClear"
,
loadcfg32
->
GlobalFlagsClear
);
print_dword
(
"GlobalFlagsSet"
,
loadcfg32
->
GlobalFlagsSet
);
print_dword
(
"CriticalSectionDefaultTimeout"
,
loadcfg32
->
CriticalSectionDefaultTimeout
);
if
(
PE_nt_headers
->
OptionalHeader
.
Magic
==
IMAGE_NT_OPTIONAL_HDR64_MAGIC
)
{
print_longlong
(
"DeCommitFreeBlockThreshold"
,
loadcfg64
->
DeCommitFreeBlockThreshold
);
print_longlong
(
"DeCommitTotalFreeThreshold"
,
loadcfg64
->
DeCommitTotalFreeThreshold
);
print_longlong
(
"MaximumAllocationSize"
,
loadcfg64
->
MaximumAllocationSize
);
print_longlong
(
"VirtualMemoryThreshold"
,
loadcfg64
->
VirtualMemoryThreshold
);
print_dword
(
"ProcessHeapFlags"
,
loadcfg64
->
ProcessHeapFlags
);
print_longlong
(
"ProcessAffinityMask"
,
loadcfg64
->
ProcessAffinityMask
);
print_word
(
"CSDVersion"
,
loadcfg64
->
CSDVersion
);
print_word
(
"Reserved"
,
loadcfg64
->
Reserved1
);
print_longlong
(
"SecurityCookie"
,
loadcfg64
->
SecurityCookie
);
print_longlong
(
"SEHandlerTable"
,
loadcfg64
->
SEHandlerTable
);
print_longlong
(
"SEHandlerCount"
,
loadcfg64
->
SEHandlerCount
);
}
else
{
print_dword
(
"DeCommitFreeBlockThreshold"
,
loadcfg32
->
DeCommitFreeBlockThreshold
);
print_dword
(
"DeCommitTotalFreeThreshold"
,
loadcfg32
->
DeCommitTotalFreeThreshold
);
print_dword
(
"MaximumAllocationSize"
,
loadcfg32
->
MaximumAllocationSize
);
print_dword
(
"VirtualMemoryThreshold"
,
loadcfg32
->
VirtualMemoryThreshold
);
print_dword
(
"ProcessHeapFlags"
,
loadcfg32
->
ProcessHeapFlags
);
print_dword
(
"ProcessAffinityMask"
,
loadcfg32
->
ProcessAffinityMask
);
print_word
(
"CSDVersion"
,
loadcfg32
->
CSDVersion
);
print_word
(
"Reserved"
,
loadcfg32
->
Reserved1
);
print_dword
(
"SecurityCookie"
,
loadcfg32
->
SecurityCookie
);
print_dword
(
"SEHandlerTable"
,
loadcfg32
->
SEHandlerTable
);
print_dword
(
"SEHandlerCount"
,
loadcfg32
->
SEHandlerCount
);
}
}
static
void
dump_dir_delay_imported_functions
(
void
)
static
void
dump_dir_delay_imported_functions
(
void
)
{
{
unsigned
directorySize
;
unsigned
directorySize
;
...
@@ -1930,6 +1976,8 @@ void pe_dump(void)
...
@@ -1930,6 +1976,8 @@ void pe_dump(void)
dump_dir_resource
();
dump_dir_resource
();
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"tls"
))
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"tls"
))
dump_dir_tls
();
dump_dir_tls
();
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"loadcfg"
))
dump_dir_loadconfig
();
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"clr"
))
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"clr"
))
dump_dir_clr_header
();
dump_dir_clr_header
();
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"reloc"
))
if
(
all
||
!
strcmp
(
globals
.
dumpsect
,
"reloc"
))
...
...
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