[svn-commits] trunk r33616 - in /trunk: ./ res/res_agi.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Mon Jun 12 08:30:33 MST 2006


Author: tilghman
Date: Mon Jun 12 10:30:32 2006
New Revision: 33616

URL: http://svn.digium.com/view/asterisk?rev=33616&view=rev
Log:
Merged revisions 33615 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r33615 | tilghman | 2006-06-12 10:27:18 -0500 (Mon, 12 Jun 2006) | 4 lines

Move set priority up, because at this point in the code, stdout is no longer
the console.  If we're unable to set priority, the error goes to Asterisk as
if it were an AGI command (issue 7335).

........

Modified:
    trunk/   (props changed)
    trunk/res/res_agi.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.

Modified: trunk/res/res_agi.c
URL: http://svn.digium.com/view/asterisk/trunk/res/res_agi.c?rev=33616&r1=33615&r2=33616&view=diff
==============================================================================
--- trunk/res/res_agi.c (original)
+++ trunk/res/res_agi.c Mon Jun 12 10:30:32 2006
@@ -305,6 +305,9 @@
 		setenv("AST_KEY_DIR", ast_config_AST_KEY_DIR, 1);
 		setenv("AST_RUN_DIR", ast_config_AST_RUN_DIR, 1);
 
+		/* Don't run AGI scripts with realtime priority -- it causes audio stutter */
+		ast_set_priority(0);
+
 		/* Redirect stdin and out, provide enhanced audio channel if desired */
 		dup2(fromast[0], STDIN_FILENO);
 		dup2(toast[1], STDOUT_FILENO);
@@ -323,9 +326,6 @@
 		/* Close everything but stdin/out/error */
 		for (x=STDERR_FILENO + 2;x<1024;x++) 
 			close(x);
-
-		/* Don't run AGI scripts with realtime priority -- it causes audio stutter */
-		ast_set_priority(0);
 
 		/* Execute script */
 		execv(script, argv);



More information about the svn-commits mailing list