This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
analysis does not like mutex being either held or released
authorJarkko Hietaniemi <jhi@iki.fi>
Thu, 19 Nov 2015 02:18:37 +0000 (21:18 -0500)
committerJarkko Hietaniemi <jhi@iki.fi>
Mon, 23 Nov 2015 11:55:12 +0000 (06:55 -0500)
threads.xs:1020:1: warning: mutex 'thread->mutex' is not held on every path through here [-Wthread-safety-analysis]
}
^

dist/threads/threads.xs

index 73f704b..9333a34 100644 (file)
@@ -1017,7 +1017,10 @@ S_ithread_create(
     my_pool->running_threads++;
     MUTEX_UNLOCK(&my_pool->create_destruct_mutex);
     return (thread);
+CLANG_DIAG_IGNORE(-Wthread-safety);
+/* warning: mutex 'thread->mutex' is not held on every path through here [-Wthread-safety-analysis] */
 }
+CLANG_DIAG_RESTORE;
 
 #endif /* USE_ITHREADS */