diff options
Diffstat (limited to 'main')
-rw-r--r-- | main/translate.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/main/translate.c b/main/translate.c index 7cfd851a6..f0685145d 100644 --- a/main/translate.c +++ b/main/translate.c @@ -818,6 +818,11 @@ unsigned int ast_translate_available_formats(unsigned int dest, unsigned int src unsigned int src_audio = powerof(src & AST_FORMAT_AUDIO_MASK); unsigned int src_video = powerof(src & AST_FORMAT_VIDEO_MASK); + /* if we don't have a source format, we just have to try all + possible destination formats */ + if (!src) + return dest; + AST_LIST_LOCK(&translators); for (x = 1; x < AST_FORMAT_MAX_AUDIO; x <<= 1) { |