Revision e63a3628 libavformat/flacdec.c

View differences:

libavformat/flacdec.c
40 40
    /* the parameters will be extracted from the compressed bitstream */
41 41

  
42 42
    /* if fLaC marker is not found, assume there is no header */
43
    if (get_le32(s->pb) != MKTAG('f','L','a','C')) {
43
    if (avio_rl32(s->pb) != MKTAG('f','L','a','C')) {
44 44
        url_fseek(s->pb, -4, SEEK_CUR);
45 45
        return 0;
46 46
    }
47 47

  
48 48
    /* process metadata blocks */
49 49
    while (!url_feof(s->pb) && !metadata_last) {
50
        get_buffer(s->pb, header, 4);
50
        avio_read(s->pb, header, 4);
51 51
        ff_flac_parse_block_header(header, &metadata_last, &metadata_type,
52 52
                                   &metadata_size);
53 53
        switch (metadata_type) {
......
58 58
            if (!buffer) {
59 59
                return AVERROR(ENOMEM);
60 60
            }
61
            if (get_buffer(s->pb, buffer, metadata_size) != metadata_size) {
61
            if (avio_read(s->pb, buffer, metadata_size) != metadata_size) {
62 62
                av_freep(&buffer);
63 63
                return AVERROR(EIO);
64 64
            }

Also available in: Unified diff