Revision 468644f6 libavformat/aviobuf.c

View differences:

libavformat/aviobuf.c
38 38
#define SHORT_SEEK_THRESHOLD 4096
39 39

  
40 40
static void fill_buffer(AVIOContext *s);
41
#if !FF_API_URL_RESETBUF
42 41
static int url_resetbuf(AVIOContext *s, int flags);
43
#endif
44 42

  
45 43
int ffio_init_context(AVIOContext *s,
46 44
                  unsigned char *buffer,
......
878 876
    return 0;
879 877
}
880 878

  
881
#if FF_API_URL_RESETBUF
882
int url_resetbuf(AVIOContext *s, int flags)
883
#else
884 879
static int url_resetbuf(AVIOContext *s, int flags)
885
#endif
886 880
{
887
#if FF_API_URL_RESETBUF
888
    if (flags & AVIO_RDWR)
889
        return AVERROR(EINVAL);
890
#else
891 881
    assert(flags == AVIO_WRONLY || flags == AVIO_RDONLY);
892
#endif
893 882

  
894 883
    if (flags & AVIO_WRONLY) {
895 884
        s->buf_end = s->buffer + s->buffer_size;

Also available in: Unified diff