st->got_frame = 0;
static void av_read_frame_flush(AVFormatContext *s){    AVStream *st;    int i;    flush_packet_queue(s);    /* free previous packet */    if (s->cur_st) {        if (s->cur_st->parser)            av_free_packet(&s->cur_pkt);        s->cur_st = NULL;    }    /* fail safe */    s->cur_ptr = NULL;    s->cur_len = 0;        /* for each stream, reset read state */    for(i = 0; i < s->nb_streams; i++) {        st = s->streams[i];                if (st->parser) {            av_parser_close(st->parser);            st->parser = NULL;        }        st->got_frame = 0;        st->cur_dts = 0; /* we set the current DTS to an unspecified origin */    }}