[cairo-commit] test/svg2png.c
Bryce Harrington
bryce at kemper.freedesktop.org
Tue Jul 28 17:13:16 PDT 2015
test/svg2png.c | 2 ++
1 file changed, 2 insertions(+)
New commits:
commit 0dd5d84baef70dad68ab67ba172edeaa1b98a995
Author: Bryce Harrington <bryce at osg.samsung.com>
Date: Tue Jul 28 17:10:33 2015 -0700
svg2png: Only call deprecated g_type_init() for old glib versions.
Quells the following warning:
pdf2png.c:52:5: warning: ‘g_type_init’ is deprecated (declared at
/usr/include/glib-2.0/gobject/gtype.h:667) [-Wdeprecated-declarations]
g_type_init ();
^
svg2png.c:47:5: warning: ‘g_type_init’ is deprecated (declared at
/usr/include/glib-2.0/gobject/gtype.h:667) [-Wdeprecated-declarations]
g_type_init ();
^
Patch authored by arpitj01 at gmail.com
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=81197
Signed-off-by: Bryce Harrington <bryce at osg.samsung.com>
diff --git a/test/svg2png.c b/test/svg2png.c
index bdfbc8b..1eecaf7 100644
--- a/test/svg2png.c
+++ b/test/svg2png.c
@@ -44,7 +44,9 @@ int main (int argc, char *argv[])
if (argc != 3)
FAIL ("usage: svg2png input_file.svg output_file.png");
+ #if GLIB_MAJOR_VERSION <= 2 && GLIB_MINOR_VERSION <= 34
g_type_init ();
+ #endif
error = NULL;
More information about the cairo-commit
mailing list