On my music archive, minidlnad wasn't anywhere near through scanning, and had already leaked in excess of 10GiB from this. The basic problem is that song_metadata has one image pointer. When it sees a picture metadata item, it mallocs some space and copies the picture to that, then sets the image pointer. That's all well and good, except FLAC (and some other formats, haven't checked them) allow more than one picture. So on the second picture, it does the same thing—except overwriting the previous pointer, thus leaking it. Simple fix: check if != NULL, ignore picture. Signed-off-by: Justin Maggard <jmaggard@netgear.com>
MiniDLNA project (c) 2009 Justin Maggard Portions (c) 2006-2007 Thomas Bernard webpage: http://sourceforge.net/projects/minidlna/ This directory contains the MiniDLNA daemon software. This software is subject to the conditions detailed in the LICENCE file provided with this distribution. Parts of the software including the discovery code are licensed under the BSD revised license which is detailed in the LICENSE.miniupnpd file provided with the distribution. More information on MiniUPnPd can be found at http://miniupnp.free.fr. The MiniDLNA daemon is an UPnP-A/V and DLNA service which serves multimedia content to compatible clients on the network. See http://www.upnp.org/ for more details on UPnP and http://www.dlna.org/ for mode details on DLNA. See the INSTALL file for instructions on compiling, installing, and configuring minidlna. Prerequisites ================== - libexif - libjpeg - libid3tag - libFLAC - libvorbis - libsqlite3 - libavformat (the ffmpeg libraries) Justin Maggard
Description
Languages
C
96.4%
M4
2.2%
Roff
0.8%
Shell
0.3%
Makefile
0.3%