Index: app.c =================================================================== --- app.c (revision 19189) +++ app.c (working copy) @@ -554,6 +554,7 @@ int dspsilence = 0; int rfmt=0; struct ast_silence_generator *silgen = NULL; + int no_audio = 0; if (silencethreshold < 0) silencethreshold = global_silence_threshold; @@ -644,6 +645,7 @@ if (!res) { ast_log(LOG_WARNING, "No audio available on %s??\n", chan->name); res = -1; + no_audio = 1; } } @@ -735,6 +737,8 @@ ast_channel_stop_silence_generator(chan, silgen); *duration = end - start; + if (no_audio && *duration >= 4) + *duration -= 4; for (x=0;xname); res = -1; + no_audio = 1; } } @@ -953,6 +959,8 @@ } ast_dsp_free(sildet); *duration = end - start; + if (no_audio && *duration >= 4) + *duration -= 4; #if 0 if (outmsg > 1) { #else