infcmd.c (jump_command): Minor simplification.
authorDoug Evans <xdje42@gmail.com>
Thu, 18 Dec 2014 09:32:59 +0000 (01:32 -0800)
committerDoug Evans <xdje42@gmail.com>
Thu, 18 Dec 2014 09:32:59 +0000 (01:32 -0800)
gdb/ChangeLog:

* infcmd.c (jump_command): Minor simplification.

gdb/ChangeLog
gdb/infcmd.c

index c7b4b21fc870768010a0e110b399f7ee26a61c76..4c87d955c5e6b173526665d08a868a9c054ca2ee 100644 (file)
@@ -1,3 +1,7 @@
+2014-12-18  Doug Evans  <xdje42@gmail.com>
+
+       * infcmd.c (jump_command): Minor simplification.
+
 2014-12-18  Doug Evans  <xdje42@gmail.com>
 
        * language.c (language_lookup_primitive_type): Renamed from
index de0d24dda877bb92d04213f59fb23c3c470bd0dd..9d0a527bacffc5f3f309015bcc03369d23a79ed5 100644 (file)
@@ -1199,9 +1199,12 @@ jump_command (char *arg, int from_tty)
 
   if (sfn != NULL)
     {
+      struct obj_section *section;
+
       fixup_symbol_section (sfn, 0);
-      if (section_is_overlay (SYMBOL_OBJ_SECTION (SYMBOL_OBJFILE (sfn), sfn)) &&
-         !section_is_mapped (SYMBOL_OBJ_SECTION (SYMBOL_OBJFILE (sfn), sfn)))
+      section = SYMBOL_OBJ_SECTION (SYMBOL_OBJFILE (sfn), sfn);
+      if (section_is_overlay (section)
+         && !section_is_mapped (section))
        {
          if (!query (_("WARNING!!!  Destination is in "
                        "unmapped overlay!  Jump anyway? ")))