avmux: Remove unneeded constant variable
authorEdward Hervey <edward@centricular.com>
Fri, 11 May 2018 12:19:42 +0000 (14:19 +0200)
committerEdward Hervey <bilboed@bilboed.com>
Fri, 11 May 2018 12:19:42 +0000 (14:19 +0200)
Since the removal of the gif hacks, the variable was always set to
its default value of FALSE. Just remove it.

CID #1433656

ext/libav/gstavmux.c

index 907424b..eb93151 100644 (file)
@@ -726,7 +726,6 @@ gst_ffmpegmux_collected (GstCollectPads * pads, gpointer user_data)
   if (best_pad != NULL) {
     GstBuffer *buf;
     AVPacket pkt;
-    gboolean need_free = FALSE;
     GstMapInfo map;
 
     /* push out current buffer */
@@ -757,11 +756,7 @@ gst_ffmpegmux_collected (GstCollectPads * pads, gpointer user_data)
     else
       pkt.duration = 0;
     av_write_frame (ffmpegmux->context, &pkt);
-    if (need_free) {
-      g_free (pkt.data);
-    } else {
-      gst_buffer_unmap (buf, &map);
-    }
+    gst_buffer_unmap (buf, &map);
     gst_buffer_unref (buf);
   } else {
     /* close down */