changeset 129:dae03298753f trunk

[svn] - don't cancel threads that don't exist (TODO: GThreadify)
author nenolod
date Fri, 27 Oct 2006 11:55:45 -0700
parents d358a61fe55e
children 16e2c64d8b2b
files ChangeLog src/alarm/alarm.c
diffstat 2 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Fri Oct 27 11:49:25 2006 -0700
+++ b/ChangeLog	Fri Oct 27 11:55:45 2006 -0700
@@ -1,3 +1,11 @@
+2006-10-27 18:49:25 +0000  William Pitcock <nenolod@nenolod.net>
+  revision [256]
+  - enable legacy GTK APIs for alarm
+  
+  trunk/src/alarm/Makefile |    2 +-
+  1 file changed, 1 insertion(+), 1 deletion(-)
+
+
 2006-10-26 19:41:45 +0000  William Pitcock <nenolod@nenolod.net>
   revision [254]
   - echo plugin support by Christian Birchinger <joker -at- gentoo.org>
--- a/src/alarm/alarm.c	Fri Oct 27 11:49:25 2006 -0700
+++ b/src/alarm/alarm.c	Fri Oct 27 11:55:45 2006 -0700
@@ -1000,10 +1000,12 @@
 {
    DEBUG("alarm_cleanup\n");
 
-   pthread_cancel(start_tid);
+   if (start_tid)
+     pthread_cancel(start_tid);
    start_tid = 0;
    if(stop_tid)
      pthread_cancel(stop_tid);
+   stop_tid = 0;
 }
 
 /*