diff options
author | Petar Petrov | 2013-06-03 23:27:37 +0200 |
---|---|---|
committer | Robby Workman | 2013-06-04 07:11:33 +0200 |
commit | 9a1f447dfc912da1dbb9c656ee1ab54cbb8af686 (patch) | |
tree | bc879b2ab623028224152b9220dc3958633e8a8f /graphics/gpaint/patches/21_fix_crash_on_fill_button_click.patch | |
parent | bf4ab6962d0aa471d1906c66041b0f45f8e0391f (diff) | |
download | slackbuilds-9a1f447dfc912da1dbb9c656ee1ab54cbb8af686.tar.gz |
graphics/gpaint: Added (GNU Paint: a small-scale GTK2 painting program)
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'graphics/gpaint/patches/21_fix_crash_on_fill_button_click.patch')
-rw-r--r-- | graphics/gpaint/patches/21_fix_crash_on_fill_button_click.patch | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/graphics/gpaint/patches/21_fix_crash_on_fill_button_click.patch b/graphics/gpaint/patches/21_fix_crash_on_fill_button_click.patch new file mode 100644 index 0000000000..132b349030 --- /dev/null +++ b/graphics/gpaint/patches/21_fix_crash_on_fill_button_click.patch @@ -0,0 +1,25 @@ +Author: Goedson Teixeira Paixao <goedson@debian.org> +Description: fix crash on fill button click + Avoid crashing when clicking on fill button by checking that + tool->canvas->drawing_area is not null before casting it to GtkWidget +Bug-Debian: http://bugs.debian.org/544162 +Bug-Ubuntu: https://bugs.edge.launchpad.net/ubuntu/+source/gpaint/+bug/227174 +Bug: https://savannah.gnu.org/bugs/?25117 +Forwarded: https://savannah.gnu.org/patch/?7045 + +Index: pkg-gpaint/src/text.c +=================================================================== +--- pkg-gpaint.orig/src/text.c 2009-12-22 21:03:29.000000000 -0200 ++++ pkg-gpaint/src/text.c 2009-12-23 13:01:33.000000000 -0200 +@@ -156,7 +156,10 @@ + { + debug_fn(); + GtkStyle *style; +- GtkWidget *widget = GTK_WIDGET(tool->canvas->drawing_area); ++ GtkWidget *widget = NULL; ++ ++ if ((tool->canvas == NULL) || (tool->canvas->drawing_area == NULL)) return FALSE; ++ widget = GTK_WIDGET(tool->canvas->drawing_area); + style = gtk_widget_get_style(widget); + g_assert(style); + |