Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
16a3481b
Commit
16a3481b
authored
Mar 25, 2020
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 25, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbghelp: Use loader_ops for enum_modules.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
093616ee
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
15 additions
and
22 deletions
+15
-22
dbghelp_private.h
dlls/dbghelp/dbghelp_private.h
+4
-5
elf_module.c
dlls/dbghelp/elf_module.c
+2
-6
macho_module.c
dlls/dbghelp/macho_module.c
+2
-6
minidump.c
dlls/dbghelp/minidump.c
+1
-5
module.c
dlls/dbghelp/module.c
+6
-0
No files found.
dlls/dbghelp/dbghelp_private.h
View file @
16a3481b
...
...
@@ -387,9 +387,12 @@ struct module
struct
wine_rb_tree
sources_offsets_tree
;
};
typedef
BOOL
(
*
enum_modules_cb
)(
const
WCHAR
*
,
unsigned
long
addr
,
void
*
user
);
struct
loader_ops
{
BOOL
(
*
synchronize_module_list
)(
struct
process
*
process
);
BOOL
(
*
enum_modules
)(
struct
process
*
process
,
enum_modules_cb
callback
,
void
*
user
);
BOOL
(
*
fetch_file_info
)(
struct
process
*
process
,
const
WCHAR
*
name
,
ULONG_PTR
load_addr
,
DWORD_PTR
*
base
,
DWORD
*
size
,
DWORD
*
checksum
);
};
...
...
@@ -598,11 +601,7 @@ extern const char* wine_dbgstr_addr(const ADDRESS64* addr) DECLSPEC_HIDDEN;
extern
struct
cpu
*
cpu_find
(
DWORD
)
DECLSPEC_HIDDEN
;
extern
DWORD
calc_crc32
(
HANDLE
handle
)
DECLSPEC_HIDDEN
;
typedef
BOOL
(
*
enum_modules_cb
)(
const
WCHAR
*
,
unsigned
long
addr
,
void
*
user
);
/* elf_module.c */
extern
BOOL
elf_enum_modules
(
struct
process
*
,
enum_modules_cb
,
void
*
)
DECLSPEC_HIDDEN
;
struct
image_file_map
;
extern
BOOL
elf_load_debug_info
(
struct
module
*
module
)
DECLSPEC_HIDDEN
;
extern
struct
module
*
elf_load_module
(
struct
process
*
pcs
,
const
WCHAR
*
name
,
unsigned
long
)
DECLSPEC_HIDDEN
;
...
...
@@ -611,7 +610,6 @@ struct elf_thunk_area;
extern
int
elf_is_in_thunk_area
(
unsigned
long
addr
,
const
struct
elf_thunk_area
*
thunks
)
DECLSPEC_HIDDEN
;
/* macho_module.c */
extern
BOOL
macho_enum_modules
(
struct
process
*
,
enum_modules_cb
,
void
*
)
DECLSPEC_HIDDEN
;
extern
BOOL
macho_load_debug_info
(
struct
process
*
pcs
,
struct
module
*
module
)
DECLSPEC_HIDDEN
;
extern
struct
module
*
macho_load_module
(
struct
process
*
pcs
,
const
WCHAR
*
name
,
unsigned
long
)
DECLSPEC_HIDDEN
;
...
...
@@ -707,6 +705,7 @@ extern BOOL stabs_parse(struct module* module, unsigned long load_offset
stabs_def_cb
callback
,
void
*
user
)
DECLSPEC_HIDDEN
;
/* dwarf.c */
struct
image_file_map
;
extern
BOOL
dwarf2_parse
(
struct
module
*
module
,
unsigned
long
load_offset
,
const
struct
elf_thunk_area
*
thunks
,
struct
image_file_map
*
fmap
)
DECLSPEC_HIDDEN
;
...
...
dlls/dbghelp/elf_module.c
View file @
16a3481b
...
...
@@ -1502,7 +1502,7 @@ static BOOL elf_enum_modules_translate(const WCHAR* name, unsigned long load_add
* This function doesn't require that someone has called SymInitialize
* on this very process.
*/
BOOL
elf_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
static
BOOL
elf_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
{
struct
elf_info
elf_info
;
BOOL
ret
;
...
...
@@ -1706,6 +1706,7 @@ static BOOL elf_search_loader(struct process* pcs, struct elf_info* elf_info)
static
const
struct
loader_ops
elf_loader_ops
=
{
elf_synchronize_module_list
,
elf_enum_modules
,
elf_fetch_file_info
,
};
...
...
@@ -1739,11 +1740,6 @@ BOOL elf_read_wine_loader_dbg_info(struct process* pcs)
return
FALSE
;
}
BOOL
elf_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
{
return
FALSE
;
}
struct
module
*
elf_load_module
(
struct
process
*
pcs
,
const
WCHAR
*
name
,
unsigned
long
addr
)
{
return
NULL
;
...
...
dlls/dbghelp/macho_module.c
View file @
16a3481b
...
...
@@ -1730,7 +1730,7 @@ static BOOL macho_synchronize_module_list(struct process* pcs)
* This function doesn't require that someone has called SymInitialize
* on this very process.
*/
BOOL
macho_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
static
BOOL
macho_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
{
struct
macho_info
macho_info
;
BOOL
ret
;
...
...
@@ -1906,6 +1906,7 @@ static BOOL macho_search_loader(struct process* pcs, struct macho_info* macho_in
static
const
struct
loader_ops
macho_loader_ops
=
{
macho_synchronize_module_list
,
macho_enum_modules
,
macho_fetch_file_info
,
};
...
...
@@ -1935,11 +1936,6 @@ BOOL macho_read_wine_loader_dbg_info(struct process* pcs)
return
FALSE
;
}
BOOL
macho_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
{
return
FALSE
;
}
struct
module
*
macho_load_module
(
struct
process
*
pcs
,
const
WCHAR
*
name
,
unsigned
long
addr
)
{
return
NULL
;
...
...
dlls/dbghelp/minidump.c
View file @
16a3481b
...
...
@@ -320,11 +320,7 @@ static void fetch_modules_info(struct dump_context* dc)
* And it's always a good idea to have a trace of the loaded ELF modules for
* a given application in a post mortem debugging condition.
*/
if
(
dc
->
process
->
dbg_hdr_addr
)
{
elf_enum_modules
(
dc
->
process
,
fetch_host_module_info_cb
,
dc
);
macho_enum_modules
(
dc
->
process
,
fetch_host_module_info_cb
,
dc
);
}
dc
->
process
->
loader
->
enum_modules
(
dc
->
process
,
fetch_host_module_info_cb
,
dc
);
}
static
void
fetch_module_versioninfo
(
LPCWSTR
filename
,
VS_FIXEDFILEINFO
*
ffi
)
...
...
dlls/dbghelp/module.c
View file @
16a3481b
...
...
@@ -1431,6 +1431,11 @@ static BOOL native_synchronize_module_list(struct process* pcs)
return
FALSE
;
}
static
BOOL
native_enum_modules
(
struct
process
*
process
,
enum_modules_cb
cb
,
void
*
user
)
{
return
FALSE
;
}
static
BOOL
native_fetch_file_info
(
struct
process
*
process
,
const
WCHAR
*
name
,
ULONG_PTR
load_addr
,
DWORD_PTR
*
base
,
DWORD
*
size
,
DWORD
*
checksum
)
{
...
...
@@ -1440,5 +1445,6 @@ static BOOL native_fetch_file_info(struct process* process, const WCHAR* name, U
const
struct
loader_ops
no_loader_ops
=
{
native_synchronize_module_list
,
native_enum_modules
,
native_fetch_file_info
,
};
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