History

Make avfilter_unref_buffer() accept a NULL parameter.

Originally committed as revision 26373 to svn://svn.ffmpeg.org/ffmpeg/trunk

Stefano Sabatini committed 15 years ago

Commit 6baf4af1 parent 24d13eb2 files · +4 −2Browse files

Unified · Split

2 files
  1. libavfilter/avfilter.c +2 −0
  2. libavfilter/avfilter.h +2 −2
libavfilter/avfilter.c+2−0
@@ -70,6 +70,8 @@ AVFilterBufferRef *avfilter_ref_buffer(AVFilterBufferRef *ref, int pmask) · 69 unmodified lines
70 70
71void avfilter_unref_buffer(AVFilterBufferRef *ref)71void avfilter_unref_buffer(AVFilterBufferRef *ref)
72{72{
73 if (!ref)
74 return;
73 if (!(--ref->buf->refcount))75 if (!(--ref->buf->refcount))
74 ref->buf->free(ref->buf);76 ref->buf->free(ref->buf);
75 av_free(ref->video);77 av_free(ref->video);
libavfilter/avfilter.h+2−2
@@ -28,7 +28,7 @@ · 27 unmodified lines
28 28
29#define LIBAVFILTER_VERSION_MAJOR 129#define LIBAVFILTER_VERSION_MAJOR 1
30#define LIBAVFILTER_VERSION_MINOR 7330#define LIBAVFILTER_VERSION_MINOR 73
31#define LIBAVFILTER_VERSION_MICRO 131#define LIBAVFILTER_VERSION_MICRO 2
32 32
33#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \33#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
34 LIBAVFILTER_VERSION_MINOR, \34 LIBAVFILTER_VERSION_MINOR, \
@@ -177,7 +177,7 @@ AVFilterBufferRef *avfilter_ref_buffer(AVFilterBufferRef *ref, int pmask); · 142 unmodified lines
177 * Remove a reference to a buffer. If this is the last reference to the177 * Remove a reference to a buffer. If this is the last reference to the
178 * buffer, the buffer itself is also automatically freed.178 * buffer, the buffer itself is also automatically freed.
179 *179 *
180 * @param ref reference to the buffer180 * @param ref reference to the buffer, may be NULL
181 */181 */
182void avfilter_unref_buffer(AVFilterBufferRef *ref);182void avfilter_unref_buffer(AVFilterBufferRef *ref);
183 183

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t