[asterisk-commits] tilghman: branch 1.4 r163088 - /branches/1.4/res/res_agi.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Dec 11 10:51:27 CST 2008


Author: tilghman
Date: Thu Dec 11 10:51:27 2008
New Revision: 163088

URL: http://svn.digium.com/view/asterisk?view=rev&rev=163088
Log:
Don't wait forever, if there's a specified recording timeout.
(closes issue #13885)
 Reported by: bamby
 Patches: 
       res_agi.c.patch uploaded by bamby (license 430)

Modified:
    branches/1.4/res/res_agi.c

Modified: branches/1.4/res/res_agi.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/res/res_agi.c?view=diff&rev=163088&r1=163087&r2=163088
==============================================================================
--- branches/1.4/res/res_agi.c (original)
+++ branches/1.4/res/res_agi.c Thu Dec 11 10:51:27 2008
@@ -970,7 +970,7 @@
 		
 		start = ast_tvnow();
 		while ((ms < 0) || ast_tvdiff_ms(ast_tvnow(), start) < ms) {
-			res = ast_waitfor(chan, -1);
+			res = ast_waitfor(chan, ms - ast_tvdiff_ms(ast_tvnow(), start));
 			if (res < 0) {
 				ast_closestream(fs);
 				fdprintf(agi->fd, "200 result=%d (waitfor) endpos=%ld\n", res,sample_offset);




More information about the asterisk-commits mailing list