diff options
author | Artur Bergman <sky@nanisky.com> | 2002-04-21 23:29:22 +0000 |
---|---|---|
committer | Artur Bergman <sky@nanisky.com> | 2002-04-21 23:29:22 +0000 |
commit | 1ea20f421a49b3c1ecb2a2fcef2f8a40d21ccdfc (patch) | |
tree | a20130699666333fea062e88d1807d8acf762a55 | |
parent | 91f3b821ca3eaa8b7d74bb338729ba51b7b68a90 (diff) | |
download | perl-1ea20f421a49b3c1ecb2a2fcef2f8a40d21ccdfc.tar.gz |
Do not unlock mutex twice.
Do not unlock mutex after it has been destroyed and freed.
Do not email p5p without uncrossing eyes.
p4raw-id: //depot/perl@16056
-rwxr-xr-x | ext/threads/threads.xs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/threads/threads.xs b/ext/threads/threads.xs index 0e1992320c..eea6d652ad 100755 --- a/ext/threads/threads.xs +++ b/ext/threads/threads.xs @@ -198,7 +198,9 @@ ithread_mg_free(pTHX_ SV *sv, MAGIC *mg) MUTEX_UNLOCK(&thread->mutex); Perl_ithread_destruct(aTHX_ thread, "no reference"); } - MUTEX_UNLOCK(&thread->mutex); + else { + MUTEX_UNLOCK(&thread->mutex); + } } else { MUTEX_UNLOCK(&thread->mutex); |