aboutsummaryrefslogtreecommitdiffstats
path: root/channels/chan_dahdi.c
diff options
context:
space:
mode:
authorjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2009-10-06 23:51:19 +0000
committerjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2009-10-06 23:51:19 +0000
commitb5b45e91a68dbddb76035d3f3b56bb42bdda0dfc (patch)
tree38ee20b50c37ebe728bf975a2291a6c5d830d997 /channels/chan_dahdi.c
parentae5f30c5d441c4d6c935b2cce33bb6acfaac167f (diff)
Add missing unlock(s) in dahdi_read
(two cases in trunk) (closes issue #15683) Reported by: alecdavis git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@222462 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_dahdi.c')
-rw-r--r--channels/chan_dahdi.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c
index 100ce5f71..1958f5898 100644
--- a/channels/chan_dahdi.c
+++ b/channels/chan_dahdi.c
@@ -5081,7 +5081,10 @@ static struct ast_frame *dahdi_read(struct ast_channel *ast)
return NULL;
}
- if ((p->radio || (p->oprmode < 0)) && p->inalarm) return NULL;
+ if ((p->radio || (p->oprmode < 0)) && p->inalarm) {
+ ast_mutex_unlock(&p->lock);
+ return NULL;
+ }
p->subs[index].f.frametype = AST_FRAME_NULL;
p->subs[index].f.datalen = 0;