2011-03-25 Kai Tietz <ktietz@redhat.com>
authorKai Tietz <kai.tietz@onevision.com>
Fri, 25 Mar 2011 09:57:37 +0000 (09:57 +0000)
committerKai Tietz <kai.tietz@onevision.com>
Fri, 25 Mar 2011 09:57:37 +0000 (09:57 +0000)
        * tui/tui-source.c (tui_set_source_content): Use filename_cmp
        instead of strcmp for comparison.
        (tui_source_is_displayed): Likewise.
        * tui/tui-winsource.c (tui_update_breakpoint_info): Likewise.

gdb/ChangeLog
gdb/tui/tui-source.c
gdb/tui/tui-winsource.c

index 0b9e72dc3d9b5aa8d34a27c45c0ebefa50bca5ad..116b75ada38e97cc72603cdf9ae652e5ec9cdedf 100644 (file)
@@ -1,3 +1,10 @@
+2011-03-25  Kai Tietz  <ktietz@redhat.com>
+
+       * tui/tui-source.c (tui_set_source_content): Use filename_cmp
+       instead of strcmp for comparison.
+       (tui_source_is_displayed): Likewise.
+       * tui/tui-winsource.c (tui_update_breakpoint_info): Likewise.
+
 2011-03-24  Mark Wielaard  <mjw@redhat.com>
 
         * dwarf2read.c (lookup_signatured_type): Use DW_FORM_ref_sig8 in
index a46797c966d1397c4abaeebb5b6439b67a3d14b4..240ea430141116b210a493eada9cb403e1562a65 100644 (file)
@@ -28,6 +28,7 @@
 #include "source.h"
 #include "symtab.h"
 #include "objfiles.h"
+#include "filenames.h"
 
 #include "tui/tui.h"
 #include "tui/tui-data.h"
@@ -149,9 +150,9 @@ tui_set_source_content (struct symtab *s,
                      element->which_element.source.line_or_addr.u.line_no =
                        cur_line_no;
                      element->which_element.source.is_exec_point =
-                       (strcmp (((struct tui_win_element *)
-                                 locator->content[0])->which_element.locator.file_name,
-                                s->filename) == 0
+                       (filename_cmp (((struct tui_win_element *)
+                                      locator->content[0])->which_element.locator.file_name,
+                                      s->filename) == 0
                         && cur_line_no == ((struct tui_win_element *)
                                            locator->content[0])->which_element.locator.line_no);
                      if (c != EOF)
@@ -335,10 +336,10 @@ int
 tui_source_is_displayed (char *fname)
 {
   return (TUI_SRC_WIN->generic.content_in_use 
-         && (strcmp (((struct tui_win_element *)
-                      (tui_locator_win_info_ptr ())->
-                      content[0])->which_element.locator.file_name,
-                     fname) == 0));
+         && (filename_cmp (((struct tui_win_element *)
+                            (tui_locator_win_info_ptr ())->
+                            content[0])->which_element.locator.file_name,
+                           fname) == 0));
 }
 
 
index a7b594581412f027c7d81c44c22fb1615663f577..4c8658d5156e2e532cf721e99fb5844599e3f1ec 100644 (file)
@@ -28,6 +28,7 @@
 #include "value.h"
 #include "source.h"
 #include "objfiles.h"
+#include "filenames.h"
 
 #include "tui/tui.h"
 #include "tui/tui-data.h"
@@ -458,7 +459,7 @@ tui_update_breakpoint_info (struct tui_win_info *win,
                      || line->line_or_addr.loa == LOA_ADDRESS);
           if ((win == TUI_SRC_WIN
                && bp->source_file
-               && (strcmp (src->filename, bp->source_file) == 0)
+               && (filename_cmp (src->filename, bp->source_file) == 0)
               && line->line_or_addr.loa == LOA_LINE
                && bp->line_number == line->line_or_addr.u.line_no)
               || (win == TUI_DISASM_WIN