Add some more locking as well as API update for libss7 for new transport types
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89067 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
parent
9f08e7e132
commit
ebf9f0bc0e
|
@ -8683,10 +8683,15 @@ static void *ss7_linkset(void *data)
|
|||
}
|
||||
}
|
||||
|
||||
if (pollers[i].revents & POLLIN)
|
||||
if (pollers[i].revents & POLLIN) {
|
||||
ast_mutex_lock(&linkset->lock);
|
||||
res = ss7_read(ss7, pollers[i].fd);
|
||||
ast_mutex_unlock(&linkset->lock);
|
||||
}
|
||||
if (pollers[i].revents & POLLOUT) {
|
||||
ast_mutex_lock(&linkset->lock);
|
||||
res = ss7_write(ss7, pollers[i].fd);
|
||||
ast_mutex_unlock(&linkset->lock);
|
||||
if (res < 0) {
|
||||
ast_log(LOG_ERROR, "Error in write %s", strerror(errno));
|
||||
}
|
||||
|
@ -11771,7 +11776,7 @@ static int linkset_addsigchan(int sigchan)
|
|||
return -1;
|
||||
}
|
||||
|
||||
ss7_add_link(link->ss7, link->fds[curfd]);
|
||||
ss7_add_link(link->ss7, SS7_TRANSPORT_ZAP, link->fds[curfd]);
|
||||
link->numsigchans++;
|
||||
|
||||
memset(&si, 0, sizeof(si));
|
||||
|
|
Loading…
Reference in New Issue