Revision 0fb7a2b9 libavformat/matroska.c

View differences:

libavformat/matroska.c
2698 2698
    int res = 0;
2699 2699
    uint32_t id;
2700 2700

  
2701
    /* Do we still have a packet queued? */
2702
    if (matroska_deliver_packet(matroska, pkt) == 0)
2703
        return 0;
2701
    /* Read stream until we have a packet queued. */
2702
    while (matroska_deliver_packet(matroska, pkt)) {
2704 2703

  
2705 2704
    /* Have we already reached the end? */
2706 2705
    if (matroska->done)
......
2708 2707

  
2709 2708
    while (res == 0) {
2710 2709
        if (!(id = ebml_peek_id(matroska, &matroska->level_up))) {
2711
            res = AVERROR_IO;
2712
            break;
2710
            return AVERROR_IO;
2713 2711
        } else if (matroska->level_up) {
2714 2712
            matroska->level_up--;
2715 2713
            break;
......
2737 2735

  
2738 2736
    if (res == -1)
2739 2737
        matroska->done = 1;
2738
    }
2740 2739

  
2741
    return matroska_deliver_packet(matroska, pkt);
2740
    return 0;
2742 2741
}
2743 2742

  
2744 2743
static int

Also available in: Unified diff