set ptr to NULL after free
authorPhilip Kovacs <pkovacs@users.sourceforge.net>
Wed, 15 Nov 2006 01:48:06 +0000 (01:48 +0000)
committerPhilip Kovacs <pkovacs@users.sourceforge.net>
Wed, 15 Nov 2006 01:48:06 +0000 (01:48 +0000)
git-svn-id: https://conky.svn.sourceforge.net/svnroot/conky/trunk/conky1@773 7f574dfc-610e-0410-a909-a81674777703

src/timed_thread.c

index 32134b6..6c59c41 100644 (file)
@@ -27,7 +27,7 @@ struct _timed_thread
     unsigned int interval_usecs;       /* firing interval in microseconds */
 };
 
-/* linked list of created threadsa */
+/* linked list of created threads */
 typedef struct _timed_thread_list
 {
     timed_thread *p_timed_thread;
@@ -212,6 +212,7 @@ timed_thread_destroy_registered_threads (void)
        p_next = p_node->next;
        timed_thread_destroy (p_node->p_timed_thread, p_node->addr_of_p_timed_thread);
        free (p_node);
+       p_node=NULL:
     }
 
     p_timed_thread_list_head = NULL;