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
905ab998
Commit
905ab998
authored
Apr 06, 2009
by
Ken Thomases
Committed by
Alexandre Julliard
Apr 07, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbghelp/stabs: For Mach-O, line offset is relative to original function address.
parent
9988cbce
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
stabs.c
dlls/dbghelp/stabs.c
+7
-4
No files found.
dlls/dbghelp/stabs.c
View file @
905ab998
...
@@ -1131,6 +1131,7 @@ struct pending_line
...
@@ -1131,6 +1131,7 @@ struct pending_line
int
source_idx
;
int
source_idx
;
int
line_num
;
int
line_num
;
unsigned
long
offset
;
unsigned
long
offset
;
unsigned
long
load_offset
;
};
};
struct
pending_object
struct
pending_object
...
@@ -1177,13 +1178,15 @@ static inline void pending_add_var(struct pending_list* pending, const char* nam
...
@@ -1177,13 +1178,15 @@ static inline void pending_add_var(struct pending_list* pending, const char* nam
}
}
static
inline
void
pending_add_line
(
struct
pending_list
*
pending
,
int
source_idx
,
static
inline
void
pending_add_line
(
struct
pending_list
*
pending
,
int
source_idx
,
int
line_num
,
unsigned
long
offset
)
int
line_num
,
unsigned
long
offset
,
unsigned
long
load_offset
)
{
{
pending_make_room
(
pending
);
pending_make_room
(
pending
);
pending
->
objs
[
pending
->
num
].
tag
=
PENDING_LINE
;
pending
->
objs
[
pending
->
num
].
tag
=
PENDING_LINE
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
source_idx
=
source_idx
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
source_idx
=
source_idx
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
line_num
=
line_num
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
line_num
=
line_num
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
offset
=
offset
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
offset
=
offset
;
pending
->
objs
[
pending
->
num
].
u
.
line
.
load_offset
=
load_offset
;
pending
->
num
++
;
pending
->
num
++
;
}
}
...
@@ -1203,7 +1206,7 @@ static void pending_flush(struct pending_list* pending, struct module* module,
...
@@ -1203,7 +1206,7 @@ static void pending_flush(struct pending_list* pending, struct module* module,
break
;
break
;
case
PENDING_LINE
:
case
PENDING_LINE
:
if
(
module
->
type
==
DMT_MACHO
)
if
(
module
->
type
==
DMT_MACHO
)
pending
->
objs
[
i
].
u
.
line
.
offset
-=
func
->
address
;
pending
->
objs
[
i
].
u
.
line
.
offset
-=
func
->
address
-
pending
->
objs
[
i
].
u
.
line
.
load_offset
;
symt_add_func_line
(
module
,
func
,
pending
->
objs
[
i
].
u
.
line
.
source_idx
,
symt_add_func_line
(
module
,
func
,
pending
->
objs
[
i
].
u
.
line
.
source_idx
,
pending
->
objs
[
i
].
u
.
line
.
line_num
,
pending
->
objs
[
i
].
u
.
line
.
offset
);
pending
->
objs
[
i
].
u
.
line
.
line_num
,
pending
->
objs
[
i
].
u
.
line
.
offset
);
break
;
break
;
...
@@ -1489,12 +1492,12 @@ BOOL stabs_parse(struct module* module, unsigned long load_offset,
...
@@ -1489,12 +1492,12 @@ BOOL stabs_parse(struct module* module, unsigned long load_offset,
{
{
unsigned
long
offset
=
stab_ptr
->
n_value
;
unsigned
long
offset
=
stab_ptr
->
n_value
;
if
(
module
->
type
==
DMT_MACHO
)
if
(
module
->
type
==
DMT_MACHO
)
offset
-=
curr_func
->
address
;
offset
-=
curr_func
->
address
-
load_offset
;
symt_add_func_line
(
module
,
curr_func
,
source_idx
,
symt_add_func_line
(
module
,
curr_func
,
source_idx
,
stab_ptr
->
n_desc
,
offset
);
stab_ptr
->
n_desc
,
offset
);
}
}
else
pending_add_line
(
&
pending_func
,
source_idx
,
stab_ptr
->
n_desc
,
else
pending_add_line
(
&
pending_func
,
source_idx
,
stab_ptr
->
n_desc
,
stab_ptr
->
n_value
);
stab_ptr
->
n_value
,
load_offset
);
break
;
break
;
case
N_FUN
:
case
N_FUN
:
/*
/*
...
...
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