Line
Link Here
|
0 |
-- a/util/srcline.c |
0 |
++ b/util/srcline.c |
Lines 193-208
static void find_address_in_section(bfd *abfd, asection *section, void *data)
Link Here
|
193 |
bfd_vma pc, vma; |
193 |
bfd_vma pc, vma; |
194 |
bfd_size_type size; |
194 |
bfd_size_type size; |
195 |
struct a2l_data *a2l = data; |
195 |
struct a2l_data *a2l = data; |
|
|
196 |
flagword flags; |
196 |
|
197 |
|
197 |
if (a2l->found) |
198 |
if (a2l->found) |
198 |
return; |
199 |
return; |
199 |
|
200 |
|
200 |
if ((bfd_get_section_flags(abfd, section) & SEC_ALLOC) == 0) |
201 |
#ifdef bfd_get_section_flags |
|
|
202 |
flags = bfd_get_section_flags(abfd, section); |
203 |
#else |
204 |
flags = bfd_section_flags(section); |
205 |
#endif |
206 |
if ((flags & SEC_ALLOC) == 0) |
201 |
return; |
207 |
return; |
202 |
|
208 |
|
203 |
pc = a2l->addr; |
209 |
pc = a2l->addr; |
|
|
210 |
#ifdef bfd_get_section_vma |
204 |
vma = bfd_get_section_vma(abfd, section); |
211 |
vma = bfd_get_section_vma(abfd, section); |
|
|
212 |
#else |
213 |
vma = bfd_section_vma(section); |
214 |
#endif |
215 |
#ifdef bfd_get_section_size |
205 |
size = bfd_get_section_size(section); |
216 |
size = bfd_get_section_size(section); |
|
|
217 |
#else |
218 |
size = bfd_section_size(section); |
219 |
#endif |
206 |
|
220 |
|
207 |
if (pc < vma || pc >= vma + size) |
221 |
if (pc < vma || pc >= vma + size) |
208 |
return; |
222 |
return; |