From f73698c0cbfa2df50a12d6e293844d8e65dc55c3 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Tue, 12 Jul 2011 11:01:53 +0000 Subject: [PATCH] Reacted on warning of cppcheck about libburn/async.c --- cdrskin/cdrskin_timestamp.h | 2 +- libburn/async.c | 13 ++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/cdrskin/cdrskin_timestamp.h b/cdrskin/cdrskin_timestamp.h index b856a7e..4a11e85 100644 --- a/cdrskin/cdrskin_timestamp.h +++ b/cdrskin/cdrskin_timestamp.h @@ -1 +1 @@ -#define Cdrskin_timestamP "2011.07.12.105955" +#define Cdrskin_timestamP "2011.07.12.110131" diff --git a/libburn/async.c b/libburn/async.c index 4a7eae2..f68c88b 100644 --- a/libburn/async.c +++ b/libburn/async.c @@ -1,7 +1,7 @@ /* -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 8; -*- */ /* Copyright (c) 2004 - 2006 Derek Foreman, Ben Jansens - Copyright (c) 2006 - 2010 Thomas Schmitt + Copyright (c) 2006 - 2011 Thomas Schmitt Provided under GPL version 2 or later. */ @@ -183,11 +183,6 @@ static void remove_worker(pthread_t th) { struct w_list *a, *l = NULL; -#ifdef Libburn_detach_done_workeR - int ret; - char msg[80]; -#endif - for (a = workers; a; l = a, a = a->next) if (a->thread == th) { if (l) @@ -200,8 +195,12 @@ static void remove_worker(pthread_t th) /* Alternative : threads get detached and thus should dispose themselves. */ - ret = pthread_detach(th); + pthread_detach(th); /* + int ret; + char msg[80]; + + ret = pthread_detach(th); sprintf(msg, "remove_workers(): pid= %lu pthread_detach(%lu)= %d", (unsigned long) getpid(), (unsigned long) th, ret);