Revision b2dd842d libavformat/rdt.c

View differences:

libavformat/rdt.c
63 63
    do {
64 64
        s->n_streams++;
65 65
    } while (first_stream_of_set_idx + s->n_streams < ic->nb_streams &&
66
             s->streams[s->n_streams]->priv_data == s->streams[0]->priv_data);
66
             s->streams[s->n_streams]->id == s->streams[0]->id);
67 67
    s->prev_set_id    = -1;
68 68
    s->prev_stream_id = -1;
69 69
    s->prev_timestamp = -1;
......
76 76
void
77 77
ff_rdt_parse_close(RDTDemuxContext *s)
78 78
{
79
    int i;
80

  
81
    for (i = 1; i < s->n_streams; i++)
82
        s->streams[i]->priv_data = NULL;
83

  
84 79
    av_free(s);
85 80
}
86 81

  
......
422 417
        int n, first = -1;
423 418

  
424 419
        for (n = 0; n < s->nb_streams; n++)
425
            if (s->streams[n]->priv_data == stream->priv_data) {
420
            if (s->streams[n]->id == stream->id) {
426 421
                int count = s->streams[n]->index + 1;
427 422
                if (first == -1) first = n;
428 423
                if (rdt->nb_rmst < count) {
......
463 458
{
464 459
    AVStream *st;
465 460

  
466
    if (!(st = av_new_stream(s, 0)))
461
    if (!(st = av_new_stream(s, orig_st->id)))
467 462
        return NULL;
468 463
    st->codec->codec_type = orig_st->codec->codec_type;
469
    st->priv_data         = orig_st->priv_data;
470 464
    st->first_dts         = orig_st->first_dts;
471 465

  
472 466
    return st;

Also available in: Unified diff