static int flv_read_header(AVFormatContext *s)

{

    int flags;

    FLVContext *flv = s->priv_data;

    int offset;



    avio_skip(s->pb, 4);

    flags = avio_r8(s->pb);



    flv->missing_streams = flags & (FLV_HEADER_FLAG_HASVIDEO | FLV_HEADER_FLAG_HASAUDIO);



    s->ctx_flags |= AVFMTCTX_NOHEADER;



    offset = avio_rb32(s->pb);

    avio_seek(s->pb, offset, SEEK_SET);

    avio_skip(s->pb, 4);



    s->start_time = 0;

    flv->sum_flv_tag_size = 0;

    flv->last_keyframe_stream_index = -1;



    return 0;

}

static int flv_read_header(AVFormatContext *s)

{

    int flags;

    FLVContext *flv = s->priv_data;

    int offset;



    avio_skip(s->pb, 4);

    flags = avio_r8(s->pb);



    flv->missing_streams = flags & (FLV_HEADER_FLAG_HASVIDEO | FLV_HEADER_FLAG_HASAUDIO);



    s->ctx_flags |= AVFMTCTX_NOHEADER;



    offset = avio_rb32(s->pb);

    avio_seek(s->pb, offset, SEEK_SET);

    avio_skip(s->pb, 4);



    s->start_time = 0;

    flv->sum_flv_tag_size = 0;

    flv->last_keyframe_stream_index = -1;



    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0)

{

    int VAR_1;

    FLVContext *flv = VAR_0->priv_data;

    int VAR_2;



    avio_skip(VAR_0->pb, 4);

    VAR_1 = avio_r8(VAR_0->pb);



    flv->missing_streams = VAR_1 & (FLV_HEADER_FLAG_HASVIDEO | FLV_HEADER_FLAG_HASAUDIO);



    VAR_0->ctx_flags |= AVFMTCTX_NOHEADER;



    VAR_2 = avio_rb32(VAR_0->pb);

    avio_seek(VAR_0->pb, VAR_2, SEEK_SET);

    avio_skip(VAR_0->pb, 4);



    VAR_0->start_time = 0;

    flv->sum_flv_tag_size = 0;

    flv->last_keyframe_stream_index = -1;



    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0)
{ int VAR_1; FLVContext *flv = VAR_0->priv_data; int VAR_2; avio_skip(VAR_0->pb, 4); VAR_1 = avio_r8(VAR_0->pb); flv->missing_streams = VAR_1 & (FLV_HEADER_FLAG_HASVIDEO | FLV_HEADER_FLAG_HASAUDIO); VAR_0->ctx_flags |= AVFMTCTX_NOHEADER; VAR_2 = avio_rb32(VAR_0->pb); avio_seek(VAR_0->pb, VAR_2, SEEK_SET); avio_skip(VAR_0->pb, 4); VAR_0->start_time = 0; flv->sum_flv_tag_size = 0; flv->last_keyframe_stream_index = -1; return 0; }