[gdb] Fix -Wparentheses warnings
2016-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com> * symfile.c (find_pc_overlay): Add braces to avoid -Wparentheses warning. (find_pc_mapped_section): Likewise. (list_overlays_command): Likewise.
This commit is contained in:
parent
a1da4399c7
commit
b631e59ba0
2 changed files with 47 additions and 34 deletions
|
@ -1,3 +1,10 @@
|
|||
2016-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
|
||||
|
||||
* symfile.c (find_pc_overlay): Add braces to avoid -Wparentheses
|
||||
warning.
|
||||
(find_pc_mapped_section): Likewise.
|
||||
(list_overlays_command): Likewise.
|
||||
|
||||
2016-05-02 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* windows-nat.c (_initialize_check_for_gdb_ini): Fix off-by-one
|
||||
|
|
|
@ -3285,6 +3285,7 @@ find_pc_overlay (CORE_ADDR pc)
|
|||
struct obj_section *osect, *best_match = NULL;
|
||||
|
||||
if (overlay_debugging)
|
||||
{
|
||||
ALL_OBJSECTIONS (objfile, osect)
|
||||
if (section_is_overlay (osect))
|
||||
{
|
||||
|
@ -3298,6 +3299,7 @@ find_pc_overlay (CORE_ADDR pc)
|
|||
else if (pc_in_unmapped_range (pc, osect))
|
||||
best_match = osect;
|
||||
}
|
||||
}
|
||||
return best_match;
|
||||
}
|
||||
|
||||
|
@ -3312,9 +3314,11 @@ find_pc_mapped_section (CORE_ADDR pc)
|
|||
struct obj_section *osect;
|
||||
|
||||
if (overlay_debugging)
|
||||
{
|
||||
ALL_OBJSECTIONS (objfile, osect)
|
||||
if (pc_in_mapped_range (pc, osect) && section_is_mapped (osect))
|
||||
return osect;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
@ -3330,6 +3334,7 @@ list_overlays_command (char *args, int from_tty)
|
|||
struct obj_section *osect;
|
||||
|
||||
if (overlay_debugging)
|
||||
{
|
||||
ALL_OBJSECTIONS (objfile, osect)
|
||||
if (section_is_mapped (osect))
|
||||
{
|
||||
|
@ -3355,6 +3360,7 @@ list_overlays_command (char *args, int from_tty)
|
|||
|
||||
nmapped++;
|
||||
}
|
||||
}
|
||||
if (nmapped == 0)
|
||||
printf_filtered (_("No sections are mapped.\n"));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue