Fix a simple deadlock that was introduced _right_ before this code got merged

into trunk.

(closes issue #11895, reported by pj, patched by me)


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@101577 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.6.0
Russell Bryant 19 years ago
parent 815658d35e
commit 02357a6462

@ -17903,8 +17903,10 @@ static struct server_instance *sip_tcp_locate(struct sockaddr_in *s)
AST_LIST_TRAVERSE(&threadl, th, list) {
if ((s->sin_family == th->ser->requestor.sin_family) &&
(s->sin_addr.s_addr == th->ser->requestor.sin_addr.s_addr) &&
(s->sin_port == th->ser->requestor.sin_port))
(s->sin_port == th->ser->requestor.sin_port)) {
AST_LIST_UNLOCK(&threadl);
return th->ser;
}
}
AST_LIST_UNLOCK(&threadl);
return NULL;

Loading…
Cancel
Save