Fix the return value of ast_agi_fdprintf() to include the result from ast_carefulwrite()
authorRussell Bryant <russell@russellbryant.com>
Mon, 30 Jul 2007 19:39:52 +0000 (19:39 +0000)
committerRussell Bryant <russell@russellbryant.com>
Mon, 30 Jul 2007 19:39:52 +0000 (19:39 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@77792 65c4cc65-6c06-0410-ace0-fbb531ad65f3

res/res_agi.c

index 37e3ca9..dead361 100644 (file)
@@ -139,9 +139,7 @@ int ast_agi_fdprintf(int fd, char *fmt, ...)
        if (agidebug)
                ast_verbose("AGI Tx >> %s", buf->str);
 
-       ast_carefulwrite(fd, buf->str, buf->used, 100);
-
-       return res;
+       return ast_carefulwrite(fd, buf->str, buf->used, 100);
 }
 
 /* launch_netscript: The fastagi handler.