! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Cancel button in progress dialog missing cast
Status:
RESOLVED: FIXED

Comments

Description ToZ editbugs 2018-08-12 00:13:22 CEST
Created attachment 7882 
Fix missing CAST

With the recent commit:https://git.xfce.org/xfce/thunar/commit/?id=781a76fa6fa65410a91b700195b95e124446888d (Add label to cancel button in file operation dialog) the following is displayed during compilation:

thunar-progress-view.c: In function ‘thunar_progress_view_init’:
thunar-progress-view.c:231:25: warning: passing argument 1 of ‘gtk_button_set_label’ from incompatible pointer type [-Wincompatible-pointer-types]
   gtk_button_set_label (button, _("Cancel"));
                         ^~~~~~
In file included from /usr/include/gtk-3.0/gtk/gtk.h:54,
                 from /usr/include/exo-2/exo/exo.h:32,
                 from thunar-progress-view.c:25:
/usr/include/gtk-3.0/gtk/gtkbutton.h:123:70: note: expected ‘GtkButton *’ {aka ‘struct _GtkButton *’} but argument is of type ‘GtkWidget *’ {aka ‘struct _GtkWidget *’}
 void                  gtk_button_set_label          (GtkButton      *button,
                                                      ~~~~~~~~~~~~~~~~^~~~~~

Patch attached to add GTK_BUTTON cast.
Comment 1 Git Bot editbugs 2018-08-14 00:57:47 CEST
Andre Miranda referenced this bugreport in commit d13ef89eccb1a44d92c1cf01743bd2c930e67bba

Fix compile warning (GtkButton cast) (Bug #14601)

https://git.xfce.org/xfce/thunar/commit?id=d13ef89eccb1a44d92c1cf01743bd2c930e67bba
Comment 2 Git Bot editbugs 2018-08-14 00:58:18 CEST
Andre Miranda referenced this bugreport in commit 31b7686dad5b416b2b18fdc3fbd2bde2b96972d0

Fix compile warning (GtkButton cast) (Bug #14601)

https://git.xfce.org/xfce/thunar/commit?id=31b7686dad5b416b2b18fdc3fbd2bde2b96972d0
Comment 3 Andre Miranda editbugs 2018-08-14 01:03:22 CEST
Thanks ToZ, I didn't notice this warning because gcc 8.1 enabled new warnings, so the compile output is noisy for now, I'll get rid of them soon-ish...

Bug #14601

Reported by:
ToZ
Reported on: 2018-08-12
Last modified on: 2018-08-14

People

Assignee:
Xfce Bug Triage
CC List:
3 users

Version

Attachments

Fix missing CAST (696 bytes, patch)
2018-08-12 00:13 CEST , ToZ
no flags

Additional information