From ae49b4f2591222e902af7e8529b0e044236dfc04 Mon Sep 17 00:00:00 2001 From: CDT 1998 Larry Ewing Date: Sat, 15 Aug 1998 22:03:32 +0000 Subject: [PATCH] added a debug warning to a case that previously caused a segfault. This Sat Aug 15 16:53:45 CDT 1998 Larry Ewing * app/airbrush.c: added a debug warning to a case that previously caused a segfault. This appears to be an xinput related problem where more than one button press can occur before a button release, so if you see a warning that tells you to contact me, please do. --- ChangeLog | 7 +++++++ app/airbrush.c | 10 ++++++++-- app/paint/gimpairbrush.c | 10 ++++++++-- app/tools/airbrush.c | 10 ++++++++-- app/tools/gimpairbrushtool.c | 10 ++++++++-- 5 files changed, 39 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index ae1fa41b2a..7a19ddc393 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Sat Aug 15 16:53:45 CDT 1998 Larry Ewing + + * app/airbrush.c: added a debug warning to a case that previously + caused a segfault. This appears to be an xinput related problem + where more than one button press can occur before a button release, + so if you see a warning that tells you to contact me, please do. + Sat Aug 15 14:09:12 1998 Scott Goehring * app/transform_core.c (transform_core_do): Fixed a merge error diff --git a/app/airbrush.c b/app/airbrush.c index c3259583db..dbaa79c901 100644 --- a/app/airbrush.c +++ b/app/airbrush.c @@ -152,6 +152,12 @@ airbrush_paint_func (PaintCore *paint_core, switch (state) { case INIT_PAINT : + // timer_state = OFF; + if (timer_state == ON) + { + g_warning ("killing stray timer, please report to lewing@gimp.org"); + gtk_timeout_remove (timer); + } timer_state = OFF; break; @@ -207,11 +213,11 @@ tools_new_airbrush () void tools_free_airbrush (Tool *tool) { - paint_core_free (tool); - if (timer_state == ON) gtk_timeout_remove (timer); timer_state = OFF; + + paint_core_free (tool); } diff --git a/app/paint/gimpairbrush.c b/app/paint/gimpairbrush.c index c3259583db..dbaa79c901 100644 --- a/app/paint/gimpairbrush.c +++ b/app/paint/gimpairbrush.c @@ -152,6 +152,12 @@ airbrush_paint_func (PaintCore *paint_core, switch (state) { case INIT_PAINT : + // timer_state = OFF; + if (timer_state == ON) + { + g_warning ("killing stray timer, please report to lewing@gimp.org"); + gtk_timeout_remove (timer); + } timer_state = OFF; break; @@ -207,11 +213,11 @@ tools_new_airbrush () void tools_free_airbrush (Tool *tool) { - paint_core_free (tool); - if (timer_state == ON) gtk_timeout_remove (timer); timer_state = OFF; + + paint_core_free (tool); } diff --git a/app/tools/airbrush.c b/app/tools/airbrush.c index c3259583db..dbaa79c901 100644 --- a/app/tools/airbrush.c +++ b/app/tools/airbrush.c @@ -152,6 +152,12 @@ airbrush_paint_func (PaintCore *paint_core, switch (state) { case INIT_PAINT : + // timer_state = OFF; + if (timer_state == ON) + { + g_warning ("killing stray timer, please report to lewing@gimp.org"); + gtk_timeout_remove (timer); + } timer_state = OFF; break; @@ -207,11 +213,11 @@ tools_new_airbrush () void tools_free_airbrush (Tool *tool) { - paint_core_free (tool); - if (timer_state == ON) gtk_timeout_remove (timer); timer_state = OFF; + + paint_core_free (tool); } diff --git a/app/tools/gimpairbrushtool.c b/app/tools/gimpairbrushtool.c index c3259583db..dbaa79c901 100644 --- a/app/tools/gimpairbrushtool.c +++ b/app/tools/gimpairbrushtool.c @@ -152,6 +152,12 @@ airbrush_paint_func (PaintCore *paint_core, switch (state) { case INIT_PAINT : + // timer_state = OFF; + if (timer_state == ON) + { + g_warning ("killing stray timer, please report to lewing@gimp.org"); + gtk_timeout_remove (timer); + } timer_state = OFF; break; @@ -207,11 +213,11 @@ tools_new_airbrush () void tools_free_airbrush (Tool *tool) { - paint_core_free (tool); - if (timer_state == ON) gtk_timeout_remove (timer); timer_state = OFF; + + paint_core_free (tool); }