Summary: | [patch][regression] claws-mail deadlocking in base iconv | ||||||
---|---|---|---|---|---|---|---|
Product: | Base System | Reporter: | Fabian Keil <fk> | ||||
Component: | bin | Assignee: | Xin LI <delphij> | ||||
Status: | Closed FIXED | ||||||
Severity: | Affects Only Me | ||||||
Priority: | Normal | ||||||
Version: | Unspecified | ||||||
Hardware: | Any | ||||||
OS: | Any | ||||||
Attachments: |
|
Description
Fabian Keil
2013-10-15 13:40:00 UTC
State Changed From-To: open->patched Patch committed as r256833 against -HEAD, MFC reminder. Responsible Changed From-To: freebsd-bugs->delphij Take. Author: delphij Date: Mon Oct 21 07:58:37 2013 New Revision: 256833 URL: http://svnweb.freebsd.org/changeset/base/256833 Log: Drop cm_lock before calling mapper_close, which in turn could call _citrus_mapper_close again and result in a deadlock otherwise. This is similar to NetBSD PR/24023 (fixed in their r1.5 of this file). PR: bin/182994 Submitted by: Fabian Keil <fk fabiankeil de> MFC after: 3 days Modified: head/lib/libc/iconv/citrus_mapper.c Modified: head/lib/libc/iconv/citrus_mapper.c ============================================================================== --- head/lib/libc/iconv/citrus_mapper.c Mon Oct 21 07:49:36 2013 (r256832) +++ head/lib/libc/iconv/citrus_mapper.c Mon Oct 21 07:58:37 2013 (r256833) @@ -381,7 +381,9 @@ _citrus_mapper_close(struct _citrus_mapp _CITRUS_HASH_REMOVE(cm, cm_entry); free(cm->cm_key); } + UNLOCK(&cm_lock); mapper_close(cm); + return; quit: UNLOCK(&cm_lock); } _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" Author: delphij Date: Thu Oct 24 05:01:49 2013 New Revision: 257039 URL: http://svnweb.freebsd.org/changeset/base/257039 Log: MFC r256833: Drop cm_lock before calling mapper_close, which in turn could call _citrus_mapper_close again and result in a deadlock otherwise. This is similar to NetBSD PR/24023 (fixed in their r1.5 of this file). PR: bin/182994 Submitted by: Fabian Keil <fk fabiankeil de> Approved by: re (hrs) Modified: stable/10/lib/libc/iconv/citrus_mapper.c Directory Properties: stable/10/lib/libc/ (props changed) Modified: stable/10/lib/libc/iconv/citrus_mapper.c ============================================================================== --- stable/10/lib/libc/iconv/citrus_mapper.c Thu Oct 24 03:36:39 2013 (r257038) +++ stable/10/lib/libc/iconv/citrus_mapper.c Thu Oct 24 05:01:49 2013 (r257039) @@ -381,7 +381,9 @@ _citrus_mapper_close(struct _citrus_mapp _CITRUS_HASH_REMOVE(cm, cm_entry); free(cm->cm_key); } + UNLOCK(&cm_lock); mapper_close(cm); + return; quit: UNLOCK(&cm_lock); } _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" State Changed From-To: patched->closed MFC done as r257039 on Oct 24, 2013. Thanks for reporting this issue! |