From d13c79dd9536e8c57e117e5503d4c0226b0f066b Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Sat, 27 Dec 2014 08:15:49 -0600 Subject: Initial import of libr packaging files --- .../patches/002-fix-crash-on-malformed-icon.diff | 34 ++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 debian/squeeze/dependencies/libr/debian/patches/002-fix-crash-on-malformed-icon.diff (limited to 'debian/squeeze/dependencies/libr/debian/patches/002-fix-crash-on-malformed-icon.diff') diff --git a/debian/squeeze/dependencies/libr/debian/patches/002-fix-crash-on-malformed-icon.diff b/debian/squeeze/dependencies/libr/debian/patches/002-fix-crash-on-malformed-icon.diff new file mode 100644 index 000000000..757075f0e --- /dev/null +++ b/debian/squeeze/dependencies/libr/debian/patches/002-fix-crash-on-malformed-icon.diff @@ -0,0 +1,34 @@ +diff -ru libr-0.6.0~maverick/src/libr-icons.c libr-0.6.0/src/libr-icons.c +--- libr-0.6.0~maverick/src/libr-icons.c 2011-03-02 22:22:33.000000000 +0000 ++++ libr-0.6.0/src/libr-icons.c 2012-09-12 20:08:35.000000000 +0000 +@@ -330,18 +330,20 @@ + if(entry->type == LIBR_SVG) + { + libr_icon *icon = libr_icon_geticon_byname(handle, entry->name); +- libr_icon *icon_onecanvas; +- char *buffer; ++ if (icon) { ++ libr_icon *icon_onecanvas; ++ char *buffer; + +- /* should we report the requested size for SVG? */ +- icon->icon_size = iconsize; ++ /* should we report the requested size for SVG? */ ++ icon->icon_size = iconsize; + +- /* if the SVG is a "one canvas" document then extract the correctly sized icon */ +- if((buffer = onecanvas_geticon_bysize(icon->buffer, iconsize)) != NULL) +- { +- libr_icon_close(icon); +- icon_onecanvas = new_icon_handle(LIBR_SVG, iconsize, buffer, strlen(buffer)); +- return icon_onecanvas; ++ /* if the SVG is a "one canvas" document then extract the correctly sized icon */ ++ if((buffer = onecanvas_geticon_bysize(icon->buffer, iconsize)) != NULL) ++ { ++ libr_icon_close(icon); ++ icon_onecanvas = new_icon_handle(LIBR_SVG, iconsize, buffer, strlen(buffer)); ++ return icon_onecanvas; ++ } + } + return icon; + } -- cgit v1.2.3