]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
When returning a DTMF digit from ast_control_streamfile cast it as a char so that...
authorJoshua Colp <jcolp@digium.com>
Fri, 19 Oct 2007 16:38:29 +0000 (16:38 +0000)
committerJoshua Colp <jcolp@digium.com>
Fri, 19 Oct 2007 16:38:29 +0000 (16:38 +0000)
(closes issue #11023)
Reported by: cfc

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@86502 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/app.c

index c84bd0f54c88fd48058f9baa2f888623be0e5ae7..9136175ca701e291b5bd702fd47f35aab7ce7e4c 100644 (file)
@@ -449,6 +449,10 @@ int ast_control_streamfile(struct ast_channel *chan, const char *file,
                        break;
        }
 
+       /* If we are returning a digit cast it as char */
+       if (res > 0 || chan->stream)
+               res = (char)res;
+
        ast_stopstream(chan);
 
        return res;