GNOME Bugzilla – Bug 783031
Build failure in GNOME Continuous
Last modified: 2017-05-24 18:38:53 UTC
GJS fails to build after commit: https://git.gnome.org/browse/gjs/commit/?id=bcd1f395801f6928c419a6bd99a35eb004be9e54 Error log: ../gjs/jsapi-util-args.h: In function 'bool gjs_cairo_ps_surface_constructor(JSContext*, unsigned int, JS::Value*)': ../gjs/jsapi-util-args.h:234:23: error: 'filename' may be used uninitialized in this function [-Werror=maybe-uninitialized] g_free(*param_ref); ^ ../modules/cairo-ps-surface.cpp:42:11: note: 'filename' was declared here char *filename; ^ In file included from ../modules/cairo-svg-surface.cpp:26:0: ../gjs/jsapi-util-args.h: In function 'bool gjs_cairo_svg_surface_constructor(JSContext*, unsigned int, JS::Value*)': ../gjs/jsapi-util-args.h:234:23: error: 'filename' may be used uninitialized in this function [-Werror=maybe-uninitialized] g_free(*param_ref); ^ ../modules/cairo-svg-surface.cpp:42:11: note: 'filename' was declared here char *filename; Full build log: http://build.gnome.org/continuous/buildmaster/builds/2017/05/24/13/build/log-gjs.txt Tagged in GNOME Continuous.
Created attachment 352503 [details] [review] modules/cairo-*-surface.cpp: Silence possibly unitialized warnings Hi, This is the simple patch to ensure that we don't get the variable-may-be-unitialized warnings. This patch does successfully pass 'make distcheck' on my Ubuntu system. With blessings, thank you!
Review of attachment 352503 [details] [review]: +1
Thanks for the quick patch!