public inbox for gdb-testers@sourceware.org
help / color / mirror / Atom feed
* [binutils-gdb] Remove an unnecessary NULL check from the TUI
@ 2019-06-25 18:56 gdb-buildbot
  2019-06-25 19:08 ` Failures on Fedora-i686, branch master gdb-buildbot
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: gdb-buildbot @ 2019-06-25 18:56 UTC (permalink / raw)
  To: gdb-testers

*** TEST RESULTS FOR COMMIT ec328aa512ee09ab326d59b417836bb950083230 ***

commit ec328aa512ee09ab326d59b417836bb950083230
Author:     Tom Tromey <tom@tromey.com>
AuthorDate: Sun Jun 16 10:23:10 2019 -0600
Commit:     Tom Tromey <tom@tromey.com>
CommitDate: Tue Jun 25 07:48:25 2019 -0600

    Remove an unnecessary NULL check from the TUI
    
    In init_and_make_win, opaque_win_info can't be NULL after a new window
    is allocated.  This patch removes an unnecessary NULL check.
    
    gdb/ChangeLog
    2019-06-25  Tom Tromey  <tom@tromey.com>
    
            * tui/tui-layout.c (init_and_make_win): Remove NULL check.

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index d01d1184d9..45415df087 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,9 @@
 2019-06-25  Tom Tromey  <tom@tromey.com>
 
+	* tui/tui-layout.c (init_and_make_win): Remove NULL check.
+
+2019-06-25  Tom Tromey  <tom@tromey.com>
+
 	* tui/tui-data.h (struct tui_win_info): Make constructor
 	protected.  Make destructor virtual.  Add initializers.
 	(tui_source_window, tui_data_window, tui_cmd_window): New
diff --git a/gdb/tui/tui-layout.c b/gdb/tui/tui-layout.c
index bcae819e51..695c56012c 100644
--- a/gdb/tui/tui-layout.c
+++ b/gdb/tui/tui-layout.c
@@ -842,18 +842,16 @@ init_and_make_win (void *opaque_win_info,
   else
     generic = &((struct tui_win_info *) opaque_win_info)->generic;
 
-  if (opaque_win_info != NULL)
+  init_gen_win_info (generic, win_type, height, width, origin_x, origin_y);
+  if (!tui_win_is_auxillary (win_type))
     {
-      init_gen_win_info (generic, win_type, height, width, origin_x, origin_y);
-      if (!tui_win_is_auxillary (win_type))
-	{
-	  if (generic->type == CMD_WIN)
-	    ((struct tui_win_info *) opaque_win_info)->can_highlight = FALSE;
-	  else
-	    ((struct tui_win_info *) opaque_win_info)->can_highlight = TRUE;
-	}
-      tui_make_window (generic, box_it);
+      if (generic->type == CMD_WIN)
+	((struct tui_win_info *) opaque_win_info)->can_highlight = FALSE;
+      else
+	((struct tui_win_info *) opaque_win_info)->can_highlight = TRUE;
     }
+  tui_make_window (generic, box_it);
+
   return opaque_win_info;
 }
 


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2019-07-09 17:15 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-25 18:56 [binutils-gdb] Remove an unnecessary NULL check from the TUI gdb-buildbot
2019-06-25 19:08 ` Failures on Fedora-i686, branch master gdb-buildbot
2019-06-25 19:13 ` Failures on Fedora-x86_64-m32, " gdb-buildbot
2019-06-25 19:13 ` Failures on Fedora-x86_64-cc-with-index, " gdb-buildbot
2019-06-25 19:18 ` Failures on Fedora-x86_64-m64, " gdb-buildbot
2019-06-25 19:25 ` Failures on Fedora-x86_64-native-extended-gdbserver-m32, " gdb-buildbot
2019-06-25 19:33 ` Failures on Fedora-x86_64-native-gdbserver-m32, " gdb-buildbot
2019-06-25 19:38 ` Failures on Fedora-x86_64-native-gdbserver-m64, " gdb-buildbot
2019-07-09 18:06 ` *** COMPILATION FAILED *** Failures on NetBSD-x86_64-m64, branch master *** BREAKAGE *** gdb-buildbot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).