]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
main/file: Move test event to emit PLAYBACK event more consistently
authorMatthew Jordan <mjordan@digium.com>
Thu, 14 Aug 2014 20:46:29 +0000 (20:46 +0000)
committerMatthew Jordan <mjordan@digium.com>
Thu, 14 Aug 2014 20:46:29 +0000 (20:46 +0000)
This is being done in advance of the test for ASTERISK-23953

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

main/file.c

index 715203d0eaa410233018ac98f067bb643e2d26af..ae095b9e8d564a01348e53c8d1c79a46aa061bbb 100644 (file)
@@ -985,6 +985,7 @@ int ast_streamfile(struct ast_channel *chan, const char *filename, const char *p
                return -1;
        if (vfs && ast_applystream(chan, vfs))
                return -1;
+       ast_test_suite_event_notify("PLAYBACK", "Message: %s\r\nChannel: %s", filename, chan->name);
        res = ast_playstream(fs);
        if (!res && vfs)
                res = ast_playstream(vfs);
@@ -1370,7 +1371,6 @@ int ast_stream_and_wait(struct ast_channel *chan, const char *file, const char *
 {
        int res = 0;
        if (!ast_strlen_zero(file)) {
-               ast_test_suite_event_notify("PLAYBACK", "Message: %s", file);
                res = ast_streamfile(chan, file, chan->language);
                if (!res) {
                        res = ast_waitstream(chan, digits);