if (!short_name && filename && filename_number_test(filename) >= 0) {
if (!short_name && filename && filename_number_test(filename) >= 0 && guess_image_format(filename)) {
AVOutputFormat *guess_format(const char *short_name, const char *filename,                              const char *mime_type){    AVOutputFormat *fmt, *fmt_found;    int score_max, score;    /* specific test for image sequences */    if (!short_name && filename && filename_number_test(filename) >= 0) {        return guess_format("image", NULL, NULL);    }    /* find the proper file type */    fmt_found = NULL;    score_max = 0;    fmt = first_oformat;    while (fmt != NULL) {        score = 0;        if (fmt->name && short_name && !strcmp(fmt->name, short_name))            score += 100;        if (fmt->mime_type && mime_type && !strcmp(fmt->mime_type, mime_type))            score += 10;        if (filename && fmt->extensions &&             match_ext(filename, fmt->extensions)) {            score += 5;        }        if (score > score_max) {            score_max = score;            fmt_found = fmt;        }        fmt = fmt->next;    }    return fmt_found;}   