Package: minidlna Version: 1.0.24+dfsg-1 Severity: normal Tags: patch Dear Maintainer,
I have difficulties with minidlna with large photo collections. It seems minidlna forks on every media file and quickly runs out of available RAM. I have decent amount of RAM (slightly less than 3 GiB) but that not enough. Computer starts actively using swap and then everything freezes. I found USE_FORK preprocessor directive which is enabled by default. Turning it off solved my problem. So I propose to disable it (see patch below). At least until upstream comes up with some kind of limit for forking. Thank you for considering my request. --- Rinat Ibragimov -- System Information: Debian Release: wheezy/sid APT prefers testing APT policy: (500, 'testing'), (50, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 3.2.0-4-amd64 (SMP w/2 CPU cores) Locale: LANG=ru_RU.UTF-8, LC_CTYPE=ru_RU.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages minidlna depends on: ii adduser 3.113+nmu3 ii libavformat53 6:0.8.4-1 ii libavutil51 6:0.8.4-1 ii libc6 2.13-37 ii libexif12 0.6.20-3 ii libflac8 1.2.1-6 ii libid3tag0 0.15.1b-10 ii libjpeg8 8d-1 ii libogg0 1.3.0-4 ii libsqlite3-0 3.7.13-1 ii libvorbis0a 1.3.2-1.3 ii lsb-base 4.1+Debian8 minidlna recommends no packages. minidlna suggests no packages. -- Configuration Files: /etc/minidlna.conf changed [not included] -- no debconf information
diff -ur minidlna-1.0.24+dfsg.orig/upnpglobalvars.h minidlna-1.0.24+dfsg/upnpglobalvars.h --- minidlna-1.0.24+dfsg.orig/upnpglobalvars.h 2012-02-19 14:38:34.000000000 +0400 +++ minidlna-1.0.24+dfsg/upnpglobalvars.h 2012-12-13 19:18:08.000000000 +0400 @@ -65,7 +65,7 @@ #endif #define CLIENT_CACHE_SLOTS 20 -#define USE_FORK 1 +#define USE_FORK 0 #define DB_VERSION 8 #ifdef ENABLE_NLS diff -ur minidlna-1.0.24+dfsg.orig/upnphttp.c minidlna-1.0.24+dfsg/upnphttp.c --- minidlna-1.0.24+dfsg.orig/upnphttp.c 2012-12-13 19:15:23.000000000 +0400 +++ minidlna-1.0.24+dfsg/upnphttp.c 2012-12-13 19:18:03.000000000 +0400 @@ -2006,4 +2006,5 @@ if( !newpid ) _exit(0); #endif + ; }