summaryrefslogtreecommitdiff
path: root/ffmpeg.c
diff options
context:
space:
mode:
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index f66828ffa5..d5e789e111 100644
--- a/ffmpeg.c
+++ b/ffmpeg.c
@@ -1083,7 +1083,7 @@ static int encode_audio_frame(AVFormatContext *s, OutputStream *ost,
pkt.data = NULL;
pkt.size = 0;
- if (buf) {
+ if (buf && buf_size) {
if (!ost->output_frame) {
ost->output_frame = avcodec_alloc_frame();
if (!ost->output_frame) {