aboutsummaryrefslogtreecommitdiff
path: root/games/naev/bfd.diff
blob: 7f7c1ac4667191f2b2ef43292bb8a0a66e732f79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff -Naur naev-0.7.0/src/naev.c naev-0.7.0.patched/src/naev.c
--- naev-0.7.0/src/naev.c	2017-07-15 18:51:22.000000000 -0400
+++ naev-0.7.0.patched/src/naev.c	2022-02-20 17:32:49.060133407 -0500
@@ -1375,12 +1375,11 @@
    asection *section;
 
    for (section = abfd->sections; section != NULL; section = section->next) {
-      if ((bfd_get_section_flags(abfd, section) & SEC_ALLOC) == 0)
+      if ((bfd_section_flags(section) & SEC_ALLOC) == 0)
          continue;
 
-      bfd_vma vma = bfd_get_section_vma(abfd, section);
-      bfd_size_type size = bfd_get_section_size(section);
-      if (address < vma || address >= vma + size)
+      bfd_vma vma = bfd_section_vma(section);
+      if (address < vma || address >= vma + bfd_section_size(section))
          continue;
 
       if (!bfd_find_nearest_line(abfd, section, syms, address - vma,