Revision 81b743eb

View differences:

libavformat/oggdec.c
364 364
    ogg->curidx = idx;
365 365
    os->incomplete = 0;
366 366

  
367
    if (!ogg->headers){
368
        int hdr = os->codec->header (s, idx);
369
        os->header = os->seq;
370
        if (!hdr){
367
    if (os->header) {
368
        os->header = os->codec->header (s, idx);
369
        if (!os->header){
371 370
            os->segp = segp;
372 371
            os->psize = psize;
372
            if (!ogg->headers)
373
                s->data_offset = os->sync_pos;
373 374
            ogg->headers = 1;
374
            s->data_offset = os->sync_pos;
375 375
        }else{
376 376
            os->pstart += os->psize;
377 377
            os->psize = 0;
378 378
        }
379
    }
380

  
381
    if (os->header > -1 && os->seq > os->header){
379
    } else {
382 380
        os->pflags = 0;
383 381
        os->pduration = 0;
384 382
        if (os->codec && os->codec->packet)
......
405 403
            break;
406 404
        }
407 405

  
408
    os->seq++;
409 406
    if (os->segp == os->nsegs)
410 407
        ogg->curidx = -1;
411 408

  
libavformat/oggdec.h
62 62
    unsigned int pflags;
63 63
    unsigned int pduration;
64 64
    uint32_t serial;
65
    uint32_t seq;
66 65
    uint64_t granule;
67 66
    int64_t lastpts;
68 67
    int64_t lastdts;

Also available in: Unified diff