Commit 66b22975 authored by stefano's avatar stefano

Deprecate av_fifo_realloc(). av_fifo_realloc2() should be used instead.


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@14855 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent ce22d9b1
...@@ -51,12 +51,14 @@ int av_fifo_read(AVFifoBuffer *f, uint8_t *buf, int buf_size) ...@@ -51,12 +51,14 @@ int av_fifo_read(AVFifoBuffer *f, uint8_t *buf, int buf_size)
return av_fifo_generic_read(f, buf_size, NULL, buf); return av_fifo_generic_read(f, buf_size, NULL, buf);
} }
#if LIBAVUTIL_VERSION_MAJOR < 50
/** /**
* Resizes a FIFO. * Resizes a FIFO.
*/ */
void av_fifo_realloc(AVFifoBuffer *f, unsigned int new_size) { void av_fifo_realloc(AVFifoBuffer *f, unsigned int new_size) {
av_fifo_realloc2(f, new_size); av_fifo_realloc2(f, new_size);
} }
#endif
int av_fifo_realloc2(AVFifoBuffer *f, unsigned int new_size) { int av_fifo_realloc2(AVFifoBuffer *f, unsigned int new_size) {
unsigned int old_size= f->end - f->buffer; unsigned int old_size= f->end - f->buffer;
......
...@@ -93,13 +93,15 @@ attribute_deprecated void av_fifo_write(AVFifoBuffer *f, const uint8_t *buf, int ...@@ -93,13 +93,15 @@ attribute_deprecated void av_fifo_write(AVFifoBuffer *f, const uint8_t *buf, int
*/ */
int av_fifo_generic_write(AVFifoBuffer *f, void *src, int size, int (*func)(void*, void*, int)); int av_fifo_generic_write(AVFifoBuffer *f, void *src, int size, int (*func)(void*, void*, int));
#if LIBAVUTIL_VERSION_MAJOR < 50
/** /**
* Resizes an AVFifoBuffer. * Resizes an AVFifoBuffer.
* @param *f AVFifoBuffer to resize * @param *f AVFifoBuffer to resize
* @param size new AVFifoBuffer size in bytes * @param size new AVFifoBuffer size in bytes
* @see av_fifo_realloc2() * @see av_fifo_realloc2()
*/ */
void av_fifo_realloc(AVFifoBuffer *f, unsigned int size); attribute_deprecated void av_fifo_realloc(AVFifoBuffer *f, unsigned int size);
#endif
/** /**
* Resizes an AVFifoBuffer. * Resizes an AVFifoBuffer.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment