static int process_metadata(AVFormatContext *s, uint8_t *name, uint16_t name_len,

                            uint16_t val_len, uint16_t type, AVDictionary **met)

{

    int ret;

    ff_asf_guid guid;



    if (val_len) {

        switch (type) {

        case ASF_UNICODE:

            asf_read_value(s, name, name_len, val_len, type, met);

            break;

        case ASF_BYTE_ARRAY:

            if (!strcmp(name, "WM/Picture")) // handle cover art

                asf_read_picture(s, val_len);

            else if (!strcmp(name, "ID3")) // handle ID3 tag

                get_id3_tag(s, val_len);

            else

                asf_read_value(s, name, name_len, val_len, type, met);

            break;

        case ASF_GUID:

            ff_get_guid(s->pb, &guid);

            break;

        default:

            if ((ret = asf_read_generic_value(s, name, name_len, type, met)) < 0)

                return ret;

            break;

        }

    }

    av_freep(&name);



    return 0;

}

static int process_metadata(AVFormatContext *s, uint8_t *name, uint16_t name_len,

                            uint16_t val_len, uint16_t type, AVDictionary **met)

{

    int ret;

    ff_asf_guid guid;



    if (val_len) {

        switch (type) {

        case ASF_UNICODE:

            asf_read_value(s, name, name_len, val_len, type, met);

            break;

        case ASF_BYTE_ARRAY:

            if (!strcmp(name, "WM/Picture")) 

                asf_read_picture(s, val_len);

            else if (!strcmp(name, "ID3")) 

                get_id3_tag(s, val_len);

            else

                asf_read_value(s, name, name_len, val_len, type, met);

            break;

        case ASF_GUID:

            ff_get_guid(s->pb, &guid);

            break;

        default:

            if ((ret = asf_read_generic_value(s, name, name_len, type, met)) < 0)

                return ret;

            break;

        }

    }

    av_freep(&name);



    return 0;

}

static int process_metadata(AVFormatContext *s, uint8_t *name, uint16_t name_len,     av_freep(&name);
static int FUNC_0(AVFormatContext *VAR_0, uint8_t *VAR_1, uint16_t VAR_2,

                            uint16_t VAR_3, uint16_t VAR_4, AVDictionary **VAR_5)

{

    int VAR_6;

    ff_asf_guid guid;



    if (VAR_3) {

        switch (VAR_4) {

        case ASF_UNICODE:

            asf_read_value(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4, VAR_5);

            break;

        case ASF_BYTE_ARRAY:

            if (!strcmp(VAR_1, "WM/Picture")) 

                asf_read_picture(VAR_0, VAR_3);

            else if (!strcmp(VAR_1, "ID3")) 

                get_id3_tag(VAR_0, VAR_3);

            else

                asf_read_value(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4, VAR_5);

            break;

        case ASF_GUID:

            ff_get_guid(VAR_0->pb, &guid);

            break;

        default:

            if ((VAR_6 = asf_read_generic_value(VAR_0, VAR_1, VAR_2, VAR_4, VAR_5)) < 0)

                return VAR_6;

            break;

        }

    }

    av_freep(&VAR_1);



    return 0;

}

static int FUNC_0(AVFormatContext *VAR_0, uint8_t *VAR_1, uint16_t VAR_2,
uint16_t VAR_3, uint16_t VAR_4, AVDictionary **VAR_5)
{ int VAR_6; ff_asf_guid guid; if (VAR_3) { switch (VAR_4) { case ASF_UNICODE:
asf_read_value(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4, VAR_5); break; case ASF_BYTE_ARRAY:
if (!strcmp(VAR_1, "WM/Picture"))
asf_read_picture(VAR_0, VAR_3); else if (!strcmp(VAR_1, "ID3"))
get_id3_tag(VAR_0, VAR_3); else
asf_read_value(VAR_0, VAR_1, VAR_2, VAR_3, VAR_4, VAR_5); break; case ASF_GUID:
ff_get_guid(VAR_0->pb, &guid); break; default:
if ((VAR_6 = asf_read_generic_value(VAR_0, VAR_1, VAR_2, VAR_4, VAR_5)) < 0)
return VAR_6; break; } } av_freep(&VAR_1); return 0; }