[Xfce4-commits] [apps/ristretto] 01/01: Remove dead code; found by Coverity

noreply at xfce.org noreply at xfce.org
Thu Sep 22 10:15:52 CEST 2016


This is an automated email from the git hooks/post-receive script.

f2404 pushed a commit to branch master
in repository apps/ristretto.

commit 94e8878657425a3d5149d7fbd625ced43534785a
Author: Igor <f2404 at yandex.ru>
Date:   Thu Sep 22 11:15:47 2016 +0300

    Remove dead code; found by Coverity
---
 src/main_window.c | 21 ++++-----------------
 1 file changed, 4 insertions(+), 17 deletions(-)

diff --git a/src/main_window.c b/src/main_window.c
index ef5abc9..070b1a3 100644
--- a/src/main_window.c
+++ b/src/main_window.c
@@ -2044,27 +2044,14 @@ rstto_main_window_set_navigationbar_position (RsttoMainWindow *window, guint ori
 static gboolean
 cb_rstto_main_window_navigationtoolbar_button_press_event (GtkWidget *widget, GdkEventButton *event, gpointer user_data)
 {
-    int button, event_time;
     RsttoMainWindow *window = RSTTO_MAIN_WINDOW (user_data);
-    GtkWidget *menu = NULL;
+
     if (event->button == 3 && event->type == GDK_BUTTON_PRESS)
     {
-        if (event)
-        {
-            button = event->button;
-            event_time = event->time;
-        }
-        else
-        {
-            button = 0;
-            event_time = gtk_get_current_event_time ();
-        }
-
-
-        menu = window->priv->position_menu;
-        gtk_menu_popup (GTK_MENU (menu), NULL, NULL, NULL, NULL, 
-                  button, event_time);
+        gtk_menu_popup (GTK_MENU (window->priv->position_menu), NULL, NULL, NULL, NULL,
+                event->button, event->time);
     }
+
     return FALSE;
 }
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list