[asterisk-commits] russell: branch russell/issue_12658 r163038 - /team/russell/issue_12658/main/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu Dec 11 09:40:12 CST 2008
Author: russell
Date: Thu Dec 11 09:40:12 2008
New Revision: 163038
URL: http://svn.digium.com/view/asterisk?view=rev&rev=163038
Log:
Make sure we restore the state of the alert pipe if we don't want any of the frames
from the readq.
Modified:
team/russell/issue_12658/main/channel.c
Modified: team/russell/issue_12658/main/channel.c
URL: http://svn.digium.com/view/asterisk/team/russell/issue_12658/main/channel.c?view=diff&rev=163038&r1=163037&r2=163038
==============================================================================
--- team/russell/issue_12658/main/channel.c (original)
+++ team/russell/issue_12658/main/channel.c Thu Dec 11 09:40:12 2008
@@ -2135,6 +2135,14 @@
if (!f) {
/* There were no acceptable frames on the readq. */
f = &ast_null_frame;
+ if (chan->alertpipe[0] > -1) {
+ int poke = 0;
+ /* Restore the state of the alertpipe since we aren't ready for any
+ * of the frames in the readq. */
+ if (write(chan->alertpipe[1], &poke, sizeof(poke)) != sizeof(poke)) {
+ ast_log(LOG_ERROR, "Failed to write to alertpipe: %s\n", strerror(errno));
+ }
+ }
}
/* Interpret hangup and return NULL */
More information about the asterisk-commits
mailing list