summaryrefslogtreecommitdiff
path: root/package/hotplug2/Makefile
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2009-12-09 18:50:49 +0000
committerFelix Fietkau <nbd@openwrt.org>2009-12-09 18:50:49 +0000
commit679cab88fe71ce59c158f2a6ba99b669a9069f63 (patch)
treeacc30c3875e38895d7b46a93b2d2977b70d3425f /package/hotplug2/Makefile
parentd5d8a225f886ebe776a75d5a877a5af96f658abf (diff)
downloadmtk-20170518-679cab88fe71ce59c158f2a6ba99b669a9069f63.zip
mtk-20170518-679cab88fe71ce59c158f2a6ba99b669a9069f63.tar.gz
mtk-20170518-679cab88fe71ce59c158f2a6ba99b669a9069f63.tar.bz2
Fix a memory leak in hotplug2 environment handling. Bump hotplug2 to the latest svn revision, remove obsolete patches.
Memory leak is caused by the way hotplug2 handles environment variables, using setenv() and unsetenv(). setenv() creates copies of the supplied strings, but, due to a POSIX blunder, these copies are never destroyed by unsetenv(), neither in glibc nor uclibc - not until the program terminates. Since some events are handled directly in the main process, even when configured with the "fork" worker, hotplug2 memory usage will keep growing over time. This can be observed by running "udevtrigger" and noting the increase in hotplug2 VmRSS after each run. This patch uses putenv() instead, which leaves storage management to the caller, so that we can explicitly delete stuff when it's no longer needed. Signed-off-by: Aleksandar Radovanovic <biblbroks@sezampro.rs> SVN-Revision: 18725
Diffstat (limited to 'package/hotplug2/Makefile')
-rw-r--r--package/hotplug2/Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/package/hotplug2/Makefile b/package/hotplug2/Makefile
index b51e5a9..2f8fc14 100644
--- a/package/hotplug2/Makefile
+++ b/package/hotplug2/Makefile
@@ -8,7 +8,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=hotplug2
-PKG_REV:=199
+PKG_REV:=201
PKG_VERSION:=$(PKG_REV)
PKG_RELEASE:=1