static int rm_read_audio_stream_info(AVFormatContext *s, AVIOContext *pb,

                                     AVStream *st, RMStream *ast, int read_all)

{

    char buf[256];

    uint32_t version;

    int ret;



    /* ra type header */

    version = avio_rb16(pb); /* version */

    if (version == 3) {

        int header_size = avio_rb16(pb);

        int64_t startpos = avio_tell(pb);

        avio_skip(pb, 14);

        rm_read_metadata(s, 0);

        if ((startpos + header_size) >= avio_tell(pb) + 2) {

            // fourcc (should always be "lpcJ")

            avio_r8(pb);

            get_str8(pb, buf, sizeof(buf));

        }

        // Skip extra header crap (this should never happen)

        if ((startpos + header_size) > avio_tell(pb))

            avio_skip(pb, header_size + startpos - avio_tell(pb));

        st->codec->sample_rate = 8000;

        st->codec->channels = 1;

        st->codec->codec_type = AVMEDIA_TYPE_AUDIO;

        st->codec->codec_id = CODEC_ID_RA_144;

        ast->deint_id = DEINT_ID_INT0;

    } else {

        int flavor, sub_packet_h, coded_framesize, sub_packet_size;

        int codecdata_length;

        /* old version (4) */

        avio_skip(pb, 2); /* unused */

        avio_rb32(pb); /* .ra4 */

        avio_rb32(pb); /* data size */

        avio_rb16(pb); /* version2 */

        avio_rb32(pb); /* header size */

        flavor= avio_rb16(pb); /* add codec info / flavor */

        ast->coded_framesize = coded_framesize = avio_rb32(pb); /* coded frame size */

        avio_rb32(pb); /* ??? */

        avio_rb32(pb); /* ??? */

        avio_rb32(pb); /* ??? */

        ast->sub_packet_h = sub_packet_h = avio_rb16(pb); /* 1 */

        st->codec->block_align= avio_rb16(pb); /* frame size */

        ast->sub_packet_size = sub_packet_size = avio_rb16(pb); /* sub packet size */

        avio_rb16(pb); /* ??? */

        if (version == 5) {

            avio_rb16(pb); avio_rb16(pb); avio_rb16(pb);

        }

        st->codec->sample_rate = avio_rb16(pb);

        avio_rb32(pb);

        st->codec->channels = avio_rb16(pb);

        if (version == 5) {

            ast->deint_id = avio_rl32(pb);

            avio_read(pb, buf, 4);

            buf[4] = 0;

        } else {

            get_str8(pb, buf, sizeof(buf)); /* desc */

            ast->deint_id = AV_RL32(buf);

            get_str8(pb, buf, sizeof(buf)); /* desc */

        }

        st->codec->codec_type = AVMEDIA_TYPE_AUDIO;

        st->codec->codec_tag  = AV_RL32(buf);

        st->codec->codec_id   = ff_codec_get_id(ff_rm_codec_tags,

                                                st->codec->codec_tag);



        switch (ast->deint_id) {

        case DEINT_ID_GENR:

        case DEINT_ID_INT0:

        case DEINT_ID_INT4:

        case DEINT_ID_SIPR:

        case DEINT_ID_VBRS:

        case DEINT_ID_VBRF:

            break;

        default:

            av_log(NULL,0,"Unknown interleaver %X\n", ast->deint_id);

            return AVERROR_INVALIDDATA;

        }

        switch (st->codec->codec_id) {

        case CODEC_ID_AC3:

            st->need_parsing = AVSTREAM_PARSE_FULL;

            break;

        case CODEC_ID_RA_288:

            st->codec->extradata_size= 0;

            ast->audio_framesize = st->codec->block_align;

            st->codec->block_align = coded_framesize;



            if(ast->audio_framesize >= UINT_MAX / sub_packet_h){

                av_log(s, AV_LOG_ERROR, "ast->audio_framesize * sub_packet_h too large\n");

                return -1;

            }



            av_new_packet(&ast->pkt, ast->audio_framesize * sub_packet_h);

            break;

        case CODEC_ID_COOK:

        case CODEC_ID_ATRAC3:

        case CODEC_ID_SIPR:

            avio_rb16(pb); avio_r8(pb);

            if (version == 5)

                avio_r8(pb);

            codecdata_length = avio_rb32(pb);

            if(codecdata_length + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)codecdata_length){

                av_log(s, AV_LOG_ERROR, "codecdata_length too large\n");

                return -1;

            }



            ast->audio_framesize = st->codec->block_align;

            if (st->codec->codec_id == CODEC_ID_SIPR) {

                if (flavor > 3) {

                    av_log(s, AV_LOG_ERROR, "bad SIPR file flavor %d\n",

                           flavor);

                    return -1;

                }

                st->codec->block_align = ff_sipr_subpk_size[flavor];

            } else {

                if(sub_packet_size <= 0){

                    av_log(s, AV_LOG_ERROR, "sub_packet_size is invalid\n");

                    return -1;

                }

                st->codec->block_align = ast->sub_packet_size;

            }

            if ((ret = rm_read_extradata(pb, st->codec, codecdata_length)) < 0)

                return ret;



            if(ast->audio_framesize >= UINT_MAX / sub_packet_h){

                av_log(s, AV_LOG_ERROR, "rm->audio_framesize * sub_packet_h too large\n");

                return -1;

            }



            av_new_packet(&ast->pkt, ast->audio_framesize * sub_packet_h);

            break;

        case CODEC_ID_AAC:

            avio_rb16(pb); avio_r8(pb);

            if (version == 5)

                avio_r8(pb);

            codecdata_length = avio_rb32(pb);

            if(codecdata_length + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)codecdata_length){

                av_log(s, AV_LOG_ERROR, "codecdata_length too large\n");

                return -1;

            }

            if (codecdata_length >= 1) {

                avio_r8(pb);

                if ((ret = rm_read_extradata(pb, st->codec, codecdata_length - 1)) < 0)

                    return ret;

            }

            break;

        default:

            av_strlcpy(st->codec->codec_name, buf, sizeof(st->codec->codec_name));

        }

        if (read_all) {

            avio_r8(pb);

            avio_r8(pb);

            avio_r8(pb);

            rm_read_metadata(s, 0);

        }

    }

    return 0;

}

static int rm_read_audio_stream_info(AVFormatContext *s, AVIOContext *pb,

                                     AVStream *st, RMStream *ast, int read_all)

{

    char buf[256];

    uint32_t version;

    int ret;



    

    version = avio_rb16(pb); 

    if (version == 3) {

        int header_size = avio_rb16(pb);

        int64_t startpos = avio_tell(pb);

        avio_skip(pb, 14);

        rm_read_metadata(s, 0);

        if ((startpos + header_size) >= avio_tell(pb) + 2) {

            

            avio_r8(pb);

            get_str8(pb, buf, sizeof(buf));

        }

        

        if ((startpos + header_size) > avio_tell(pb))

            avio_skip(pb, header_size + startpos - avio_tell(pb));

        st->codec->sample_rate = 8000;

        st->codec->channels = 1;

        st->codec->codec_type = AVMEDIA_TYPE_AUDIO;

        st->codec->codec_id = CODEC_ID_RA_144;

        ast->deint_id = DEINT_ID_INT0;

    } else {

        int flavor, sub_packet_h, coded_framesize, sub_packet_size;

        int codecdata_length;

        

        avio_skip(pb, 2); 

        avio_rb32(pb); 

        avio_rb32(pb); 

        avio_rb16(pb); 

        avio_rb32(pb); 

        flavor= avio_rb16(pb); 

        ast->coded_framesize = coded_framesize = avio_rb32(pb); 

        avio_rb32(pb); 

        avio_rb32(pb); 

        avio_rb32(pb); 

        ast->sub_packet_h = sub_packet_h = avio_rb16(pb); 

        st->codec->block_align= avio_rb16(pb); 

        ast->sub_packet_size = sub_packet_size = avio_rb16(pb); 

        avio_rb16(pb); 

        if (version == 5) {

            avio_rb16(pb); avio_rb16(pb); avio_rb16(pb);

        }

        st->codec->sample_rate = avio_rb16(pb);

        avio_rb32(pb);

        st->codec->channels = avio_rb16(pb);

        if (version == 5) {

            ast->deint_id = avio_rl32(pb);

            avio_read(pb, buf, 4);

            buf[4] = 0;

        } else {

            get_str8(pb, buf, sizeof(buf)); 

            ast->deint_id = AV_RL32(buf);

            get_str8(pb, buf, sizeof(buf)); 

        }

        st->codec->codec_type = AVMEDIA_TYPE_AUDIO;

        st->codec->codec_tag  = AV_RL32(buf);

        st->codec->codec_id   = ff_codec_get_id(ff_rm_codec_tags,

                                                st->codec->codec_tag);



        switch (ast->deint_id) {

        case DEINT_ID_GENR:

        case DEINT_ID_INT0:

        case DEINT_ID_INT4:

        case DEINT_ID_SIPR:

        case DEINT_ID_VBRS:

        case DEINT_ID_VBRF:

            break;

        default:

            av_log(NULL,0,"Unknown interleaver %X\n", ast->deint_id);

            return AVERROR_INVALIDDATA;

        }

        switch (st->codec->codec_id) {

        case CODEC_ID_AC3:

            st->need_parsing = AVSTREAM_PARSE_FULL;

            break;

        case CODEC_ID_RA_288:

            st->codec->extradata_size= 0;

            ast->audio_framesize = st->codec->block_align;

            st->codec->block_align = coded_framesize;



            if(ast->audio_framesize >= UINT_MAX / sub_packet_h){

                av_log(s, AV_LOG_ERROR, "ast->audio_framesize * sub_packet_h too large\n");

                return -1;

            }



            av_new_packet(&ast->pkt, ast->audio_framesize * sub_packet_h);

            break;

        case CODEC_ID_COOK:

        case CODEC_ID_ATRAC3:

        case CODEC_ID_SIPR:

            avio_rb16(pb); avio_r8(pb);

            if (version == 5)

                avio_r8(pb);

            codecdata_length = avio_rb32(pb);

            if(codecdata_length + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)codecdata_length){

                av_log(s, AV_LOG_ERROR, "codecdata_length too large\n");

                return -1;

            }



            ast->audio_framesize = st->codec->block_align;

            if (st->codec->codec_id == CODEC_ID_SIPR) {

                if (flavor > 3) {

                    av_log(s, AV_LOG_ERROR, "bad SIPR file flavor %d\n",

                           flavor);

                    return -1;

                }

                st->codec->block_align = ff_sipr_subpk_size[flavor];

            } else {

                if(sub_packet_size <= 0){

                    av_log(s, AV_LOG_ERROR, "sub_packet_size is invalid\n");

                    return -1;

                }

                st->codec->block_align = ast->sub_packet_size;

            }

            if ((ret = rm_read_extradata(pb, st->codec, codecdata_length)) < 0)

                return ret;



            if(ast->audio_framesize >= UINT_MAX / sub_packet_h){

                av_log(s, AV_LOG_ERROR, "rm->audio_framesize * sub_packet_h too large\n");

                return -1;

            }



            av_new_packet(&ast->pkt, ast->audio_framesize * sub_packet_h);

            break;

        case CODEC_ID_AAC:

            avio_rb16(pb); avio_r8(pb);

            if (version == 5)

                avio_r8(pb);

            codecdata_length = avio_rb32(pb);

            if(codecdata_length + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)codecdata_length){

                av_log(s, AV_LOG_ERROR, "codecdata_length too large\n");

                return -1;

            }

            if (codecdata_length >= 1) {

                avio_r8(pb);

                if ((ret = rm_read_extradata(pb, st->codec, codecdata_length - 1)) < 0)

                    return ret;

            }

            break;

        default:

            av_strlcpy(st->codec->codec_name, buf, sizeof(st->codec->codec_name));

        }

        if (read_all) {

            avio_r8(pb);

            avio_r8(pb);

            avio_r8(pb);

            rm_read_metadata(s, 0);

        }

    }

    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0, AVIOContext *VAR_1,

                                     AVStream *VAR_2, RMStream *VAR_3, int VAR_4)

{

    char VAR_5[256];

    uint32_t version;

    int VAR_6;



    

    version = avio_rb16(VAR_1); 

    if (version == 3) {

        int VAR_7 = avio_rb16(VAR_1);

        int64_t startpos = avio_tell(VAR_1);

        avio_skip(VAR_1, 14);

        rm_read_metadata(VAR_0, 0);

        if ((startpos + VAR_7) >= avio_tell(VAR_1) + 2) {

            

            avio_r8(VAR_1);

            get_str8(VAR_1, VAR_5, sizeof(VAR_5));

        }

        

        if ((startpos + VAR_7) > avio_tell(VAR_1))

            avio_skip(VAR_1, VAR_7 + startpos - avio_tell(VAR_1));

        VAR_2->codec->sample_rate = 8000;

        VAR_2->codec->channels = 1;

        VAR_2->codec->codec_type = AVMEDIA_TYPE_AUDIO;

        VAR_2->codec->codec_id = CODEC_ID_RA_144;

        VAR_3->deint_id = DEINT_ID_INT0;

    } else {

        int VAR_8, VAR_9, VAR_10, VAR_11;

        int VAR_12;

        

        avio_skip(VAR_1, 2); 

        avio_rb32(VAR_1); 

        avio_rb32(VAR_1); 

        avio_rb16(VAR_1); 

        avio_rb32(VAR_1); 

        VAR_8= avio_rb16(VAR_1); 

        VAR_3->VAR_10 = VAR_10 = avio_rb32(VAR_1); 

        avio_rb32(VAR_1); 

        avio_rb32(VAR_1); 

        avio_rb32(VAR_1); 

        VAR_3->VAR_9 = VAR_9 = avio_rb16(VAR_1); 

        VAR_2->codec->block_align= avio_rb16(VAR_1); 

        VAR_3->VAR_11 = VAR_11 = avio_rb16(VAR_1); 

        avio_rb16(VAR_1); 

        if (version == 5) {

            avio_rb16(VAR_1); avio_rb16(VAR_1); avio_rb16(VAR_1);

        }

        VAR_2->codec->sample_rate = avio_rb16(VAR_1);

        avio_rb32(VAR_1);

        VAR_2->codec->channels = avio_rb16(VAR_1);

        if (version == 5) {

            VAR_3->deint_id = avio_rl32(VAR_1);

            avio_read(VAR_1, VAR_5, 4);

            VAR_5[4] = 0;

        } else {

            get_str8(VAR_1, VAR_5, sizeof(VAR_5)); 

            VAR_3->deint_id = AV_RL32(VAR_5);

            get_str8(VAR_1, VAR_5, sizeof(VAR_5)); 

        }

        VAR_2->codec->codec_type = AVMEDIA_TYPE_AUDIO;

        VAR_2->codec->codec_tag  = AV_RL32(VAR_5);

        VAR_2->codec->codec_id   = ff_codec_get_id(ff_rm_codec_tags,

                                                VAR_2->codec->codec_tag);



        switch (VAR_3->deint_id) {

        case DEINT_ID_GENR:

        case DEINT_ID_INT0:

        case DEINT_ID_INT4:

        case DEINT_ID_SIPR:

        case DEINT_ID_VBRS:

        case DEINT_ID_VBRF:

            break;

        default:

            av_log(NULL,0,"Unknown interleaver %X\n", VAR_3->deint_id);

            return AVERROR_INVALIDDATA;

        }

        switch (VAR_2->codec->codec_id) {

        case CODEC_ID_AC3:

            VAR_2->need_parsing = AVSTREAM_PARSE_FULL;

            break;

        case CODEC_ID_RA_288:

            VAR_2->codec->extradata_size= 0;

            VAR_3->audio_framesize = VAR_2->codec->block_align;

            VAR_2->codec->block_align = VAR_10;



            if(VAR_3->audio_framesize >= UINT_MAX / VAR_9){

                av_log(VAR_0, AV_LOG_ERROR, "VAR_3->audio_framesize * VAR_9 too large\n");

                return -1;

            }



            av_new_packet(&VAR_3->pkt, VAR_3->audio_framesize * VAR_9);

            break;

        case CODEC_ID_COOK:

        case CODEC_ID_ATRAC3:

        case CODEC_ID_SIPR:

            avio_rb16(VAR_1); avio_r8(VAR_1);

            if (version == 5)

                avio_r8(VAR_1);

            VAR_12 = avio_rb32(VAR_1);

            if(VAR_12 + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)VAR_12){

                av_log(VAR_0, AV_LOG_ERROR, "VAR_12 too large\n");

                return -1;

            }



            VAR_3->audio_framesize = VAR_2->codec->block_align;

            if (VAR_2->codec->codec_id == CODEC_ID_SIPR) {

                if (VAR_8 > 3) {

                    av_log(VAR_0, AV_LOG_ERROR, "bad SIPR file VAR_8 %d\n",

                           VAR_8);

                    return -1;

                }

                VAR_2->codec->block_align = ff_sipr_subpk_size[VAR_8];

            } else {

                if(VAR_11 <= 0){

                    av_log(VAR_0, AV_LOG_ERROR, "VAR_11 is invalid\n");

                    return -1;

                }

                VAR_2->codec->block_align = VAR_3->VAR_11;

            }

            if ((VAR_6 = rm_read_extradata(VAR_1, VAR_2->codec, VAR_12)) < 0)

                return VAR_6;



            if(VAR_3->audio_framesize >= UINT_MAX / VAR_9){

                av_log(VAR_0, AV_LOG_ERROR, "rm->audio_framesize * VAR_9 too large\n");

                return -1;

            }



            av_new_packet(&VAR_3->pkt, VAR_3->audio_framesize * VAR_9);

            break;

        case CODEC_ID_AAC:

            avio_rb16(VAR_1); avio_r8(VAR_1);

            if (version == 5)

                avio_r8(VAR_1);

            VAR_12 = avio_rb32(VAR_1);

            if(VAR_12 + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)VAR_12){

                av_log(VAR_0, AV_LOG_ERROR, "VAR_12 too large\n");

                return -1;

            }

            if (VAR_12 >= 1) {

                avio_r8(VAR_1);

                if ((VAR_6 = rm_read_extradata(VAR_1, VAR_2->codec, VAR_12 - 1)) < 0)

                    return VAR_6;

            }

            break;

        default:

            av_strlcpy(VAR_2->codec->codec_name, VAR_5, sizeof(VAR_2->codec->codec_name));

        }

        if (VAR_4) {

            avio_r8(VAR_1);

            avio_r8(VAR_1);

            avio_r8(VAR_1);

            rm_read_metadata(VAR_0, 0);

        }

    }

    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0, AVIOContext *VAR_1,
AVStream *VAR_2, RMStream *VAR_3, int VAR_4)
{ char VAR_5[256]; uint32_t version; int VAR_6; version = avio_rb16(VAR_1); if (version == 3) { int VAR_7 = avio_rb16(VAR_1); int64_t startpos = avio_tell(VAR_1); avio_skip(VAR_1, 14); rm_read_metadata(VAR_0, 0); if ((startpos + VAR_7) >= avio_tell(VAR_1) + 2) { avio_r8(VAR_1); get_str8(VAR_1, VAR_5, sizeof(VAR_5)); } if ((startpos + VAR_7) > avio_tell(VAR_1))
avio_skip(VAR_1, VAR_7 + startpos - avio_tell(VAR_1)); VAR_2->codec->sample_rate = 8000; VAR_2->codec->channels = 1; VAR_2->codec->codec_type = AVMEDIA_TYPE_AUDIO; VAR_2->codec->codec_id = CODEC_ID_RA_144; VAR_3->deint_id = DEINT_ID_INT0; } else { int VAR_8, VAR_9, VAR_10, VAR_11; int VAR_12; avio_skip(VAR_1, 2); avio_rb32(VAR_1); avio_rb32(VAR_1); avio_rb16(VAR_1); avio_rb32(VAR_1); VAR_8= avio_rb16(VAR_1); VAR_3->VAR_10 = VAR_10 = avio_rb32(VAR_1); avio_rb32(VAR_1); avio_rb32(VAR_1); avio_rb32(VAR_1); VAR_3->VAR_9 = VAR_9 = avio_rb16(VAR_1); VAR_2->codec->block_align= avio_rb16(VAR_1); VAR_3->VAR_11 = VAR_11 = avio_rb16(VAR_1); avio_rb16(VAR_1); if (version == 5) { avio_rb16(VAR_1); avio_rb16(VAR_1); avio_rb16(VAR_1); } VAR_2->codec->sample_rate = avio_rb16(VAR_1); avio_rb32(VAR_1); VAR_2->codec->channels = avio_rb16(VAR_1); if (version == 5) { VAR_3->deint_id = avio_rl32(VAR_1); avio_read(VAR_1, VAR_5, 4); VAR_5[4] = 0; } else { get_str8(VAR_1, VAR_5, sizeof(VAR_5)); VAR_3->deint_id = AV_RL32(VAR_5); get_str8(VAR_1, VAR_5, sizeof(VAR_5)); } VAR_2->codec->codec_type = AVMEDIA_TYPE_AUDIO; VAR_2->codec->codec_tag  = AV_RL32(VAR_5); VAR_2->codec->codec_id   = ff_codec_get_id(ff_rm_codec_tags,
VAR_2->codec->codec_tag); switch (VAR_3->deint_id) { case DEINT_ID_GENR:
case DEINT_ID_INT0:
case DEINT_ID_INT4:
case DEINT_ID_SIPR:
case DEINT_ID_VBRS:
case DEINT_ID_VBRF:
break; default:
av_log(NULL,0,"Unknown interleaver %X\n", VAR_3->deint_id); return AVERROR_INVALIDDATA; } switch (VAR_2->codec->codec_id) { case CODEC_ID_AC3:
VAR_2->need_parsing = AVSTREAM_PARSE_FULL; break; case CODEC_ID_RA_288:
VAR_2->codec->extradata_size= 0; VAR_3->audio_framesize = VAR_2->codec->block_align; VAR_2->codec->block_align = VAR_10; if(VAR_3->audio_framesize >= UINT_MAX / VAR_9){ av_log(VAR_0, AV_LOG_ERROR, "VAR_3->audio_framesize * VAR_9 too large\n"); return -1; } av_new_packet(&VAR_3->pkt, VAR_3->audio_framesize * VAR_9); break; case CODEC_ID_COOK:
case CODEC_ID_ATRAC3:
case CODEC_ID_SIPR:
avio_rb16(VAR_1); avio_r8(VAR_1); if (version == 5)
avio_r8(VAR_1); VAR_12 = avio_rb32(VAR_1); if(VAR_12 + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)VAR_12){ av_log(VAR_0, AV_LOG_ERROR, "VAR_12 too large\n"); return -1; } VAR_3->audio_framesize = VAR_2->codec->block_align; if (VAR_2->codec->codec_id == CODEC_ID_SIPR) { if (VAR_8 > 3) { av_log(VAR_0, AV_LOG_ERROR, "bad SIPR file VAR_8 %d\n",
VAR_8); return -1; } VAR_2->codec->block_align = ff_sipr_subpk_size[VAR_8]; } else { if(VAR_11 <= 0){ av_log(VAR_0, AV_LOG_ERROR, "VAR_11 is invalid\n"); return -1; } VAR_2->codec->block_align = VAR_3->VAR_11; } if ((VAR_6 = rm_read_extradata(VAR_1, VAR_2->codec, VAR_12)) < 0)
return VAR_6; if(VAR_3->audio_framesize >= UINT_MAX / VAR_9){ av_log(VAR_0, AV_LOG_ERROR, "rm->audio_framesize * VAR_9 too large\n"); return -1; } av_new_packet(&VAR_3->pkt, VAR_3->audio_framesize * VAR_9); break; case CODEC_ID_AAC:
avio_rb16(VAR_1); avio_r8(VAR_1); if (version == 5)
avio_r8(VAR_1); VAR_12 = avio_rb32(VAR_1); if(VAR_12 + FF_INPUT_BUFFER_PADDING_SIZE <= (unsigned)VAR_12){ av_log(VAR_0, AV_LOG_ERROR, "VAR_12 too large\n"); return -1; } if (VAR_12 >= 1) { avio_r8(VAR_1); if ((VAR_6 = rm_read_extradata(VAR_1, VAR_2->codec, VAR_12 - 1)) < 0)
return VAR_6; } break; default:
av_strlcpy(VAR_2->codec->codec_name, VAR_5, sizeof(VAR_2->codec->codec_name)); } if (VAR_4) { avio_r8(VAR_1); avio_r8(VAR_1); avio_r8(VAR_1); rm_read_metadata(VAR_0, 0); } } return 0; }