After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 676693 - [PATCH] Fix error when compiling with -Werror=format-security
[PATCH] Fix error when compiling with -Werror=format-security
Status: RESOLVED FIXED
Product: gvfs
Classification: Core
Component: udisks2 volume monitor
git master
Other Linux
: Normal normal
: ---
Assigned To: gvfs-maint
gvfs-maint
Depends on:
Blocks:
 
 
Reported: 2012-05-23 22:54 UTC by Robert Ancell
Modified: 2012-06-30 04:43 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix error when compiling with -Werror=format-security (965 bytes, patch)
2012-05-23 22:54 UTC, Robert Ancell
none Details | Review
Fix errors when compiling with -Werror=format-security (1.61 KB, patch)
2012-05-24 00:05 UTC, Robert Ancell
none Details | Review
udisks2: Fix error when compiling with -Werror=format-security (1.66 KB, patch)
2012-06-30 04:43 UTC, Matthias Clasen
committed Details | Review

Description Robert Ancell 2012-05-23 22:54:11 UTC
Created attachment 214822 [details] [review]
Fix error when compiling with -Werror=format-security

gcc -DHAVE_CONFIG_H -I. -I../..   -D_FORTIFY_SOURCE=2 -DG_LOG_DOMAIN=\"GVFS-UDisks2\" -I../../common -I../../monitor/proxy -pthread -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/gio-unix-2.0/   -pthread -I/usr/include/udisks2 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -I/usr/include/gudev-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include    -I/usr/include/gnome-keyring-1 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -DGIO_MODULE_DIR=\"\" -DGVFS_LOCALEDIR=\""/usr/share/locale"\" -DG_DISABLE_DEPRECATED -DUDISKS_API_IS_SUBJECT_TO_CHANGE  -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -Wall -c -o gvfs_udisks2_volume_monitor-gvfsudisks2drive.o `test -f 'gvfsudisks2drive.c' || echo './'`gvfsudisks2drive.c
gcc -DHAVE_CONFIG_H -I. -I../..   -D_FORTIFY_SOURCE=2 -DG_LOG_DOMAIN=\"GVFS-UDisks2\" -I../../common -I../../monitor/proxy -pthread -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/gio-unix-2.0/   -pthread -I/usr/include/udisks2 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -I/usr/include/gudev-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include    -I/usr/include/gnome-keyring-1 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -DGIO_MODULE_DIR=\"\" -DGVFS_LOCALEDIR=\""/usr/share/locale"\" -DG_DISABLE_DEPRECATED -DUDISKS_API_IS_SUBJECT_TO_CHANGE  -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -Wall -c -o gvfs_udisks2_volume_monitor-gvfsudisks2volume.o `test -f 'gvfsudisks2volume.c' || echo './'`gvfsudisks2volume.c
gvfsudisks2volume.c: In function ‘mount_command_cb’:
gvfsudisks2volume.c:880:36: error: format not a string literal and no format arguments [-Werror=format-security]
Comment 1 Robert Ancell 2012-05-24 00:05:34 UTC
Created attachment 214825 [details] [review]
Fix errors when compiling with -Werror=format-security

Updated patch to catch second case of the same thing
Comment 2 Matthias Clasen 2012-06-30 04:43:14 UTC
The following fix has been pushed:
30b70bd udisks2: Fix error when compiling with -Werror=format-security
Comment 3 Matthias Clasen 2012-06-30 04:43:17 UTC
Created attachment 217688 [details] [review]
udisks2: Fix error when compiling with -Werror=format-security