]> git.sesse.net Git - nageru/commitdiff
Fix a memory leak in muxing.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 3 Apr 2016 15:39:10 +0000 (17:39 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sun, 3 Apr 2016 15:39:10 +0000 (17:39 +0200)
httpd.cpp

index c861fd4cfb46535123ce510a867df1bacc77cade..d6b1abd8c53d9adbc63c20d94da97ef536368a9b 100644 (file)
--- a/httpd.cpp
+++ b/httpd.cpp
@@ -224,6 +224,8 @@ void HTTPD::Mux::add_packet(const AVPacket &pkt, int64_t pts, int64_t dts)
                fprintf(stderr, "av_interleaved_write_frame() failed\n");
                exit(1);
        }
+
+       av_packet_unref(&pkt_copy);
 }
 
 HTTPD::Stream::Stream(AVOutputFormat *oformat, int width, int height)