[SCM] libav/experimental: Make avfilter_unref_buffer() accept a NULL parameter.
siretart at users.alioth.debian.org
siretart at users.alioth.debian.org
Sun Jun 30 17:22:00 UTC 2013
The following commit has been merged in the experimental branch:
commit 6baf4afa9969eea23cd4ec9b0cec3b7aed1f49af
Author: Stefano Sabatini <stefano.sabatini-lala at poste.it>
Date: Sat Jan 15 17:21:15 2011 +0000
Make avfilter_unref_buffer() accept a NULL parameter.
Originally committed as revision 26373 to svn://svn.ffmpeg.org/ffmpeg/trunk
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index 6ecd4ce..4fbb6bf 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -70,6 +70,8 @@ AVFilterBufferRef *avfilter_ref_buffer(AVFilterBufferRef *ref, int pmask)
void avfilter_unref_buffer(AVFilterBufferRef *ref)
{
+ if (!ref)
+ return;
if (!(--ref->buf->refcount))
ref->buf->free(ref->buf);
av_free(ref->video);
diff --git a/libavfilter/avfilter.h b/libavfilter/avfilter.h
index a3c51e0..5b08941 100644
--- a/libavfilter/avfilter.h
+++ b/libavfilter/avfilter.h
@@ -28,7 +28,7 @@
#define LIBAVFILTER_VERSION_MAJOR 1
#define LIBAVFILTER_VERSION_MINOR 73
-#define LIBAVFILTER_VERSION_MICRO 1
+#define LIBAVFILTER_VERSION_MICRO 2
#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
LIBAVFILTER_VERSION_MINOR, \
@@ -177,7 +177,7 @@ AVFilterBufferRef *avfilter_ref_buffer(AVFilterBufferRef *ref, int pmask);
* Remove a reference to a buffer. If this is the last reference to the
* buffer, the buffer itself is also automatically freed.
*
- * @param ref reference to the buffer
+ * @param ref reference to the buffer, may be NULL
*/
void avfilter_unref_buffer(AVFilterBufferRef *ref);
--
Libav/FFmpeg packaging
More information about the pkg-multimedia-commits
mailing list