]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/symtab.c
Approved by Jim Blandy (jimb@redhat.com).
[thirdparty/binutils-gdb.git] / gdb / symtab.c
index 743253f1d9c67979f7cba60946eb5f25bd11d146..d03a7c910769f94bef92d3db0a25b8aec148ad4d 100644 (file)
@@ -1823,6 +1823,13 @@ find_pc_sect_line (CORE_ADDR pc, struct sec *section, int notcurrent)
          val.end = alt->pc;
        }
     }
+  else if (best->line == 0)
+    {
+      /* If our best fit is in a range of PC's for which no line
+        number info is available (line number is zero) then we didn't
+        find any valid line information. */
+      val.pc = pc;
+    }
   else
     {
       val.symtab = best_symtab;