From beaea2de61c841ac3624ab9d6cd93f6bf2a76b66 Mon Sep 17 00:00:00 2001
From: Michael Niedermayer <michaelni@gmx.at>
Date: Sun, 28 Dec 2014 18:16:02 +0100
Subject: [PATCH] avdevice/dv1394: Use av_freep() to avoid leaving stale
 pointers in memory

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
---
 libavdevice/dv1394.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavdevice/dv1394.c b/libavdevice/dv1394.c
index c8241e33f22..833b65d0d08 100644
--- a/libavdevice/dv1394.c
+++ b/libavdevice/dv1394.c
@@ -206,7 +206,7 @@ static int dv1394_close(AVFormatContext * context)
         av_log(context, AV_LOG_ERROR, "Failed to munmap DV1394 ring buffer: %s\n", strerror(errno));
 
     close(dv->fd);
-    av_free(dv->dv_demux);
+    av_freep(&dv->dv_demux);
 
     return 0;
 }
-- 
GitLab