diff options
author | jow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2012-06-18 00:41:43 +0000 |
---|---|---|
committer | jow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2012-06-18 00:41:43 +0000 |
commit | 0793612583f480c051c9b4c6521a225063c758ab (patch) | |
tree | 2bbea2af541e783b6745acc3293026ea83355c46 /uhttpd-lua.c | |
parent | a0b8f9998e1f791304629220a5ff3a084bb856fc (diff) | |
download | uhttpd-0793612583f480c051c9b4c6521a225063c758ab.tar.gz |
[package] uhttpd: finish inherited uloop in forked childs, fixes misdispatched events leading to race conditions and bad memory accesses
git-svn-id: svn://svn.openwrt.org/openwrt/trunk/package/uhttpd/src@32419 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'uhttpd-lua.c')
-rw-r--r-- | uhttpd-lua.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/uhttpd-lua.c b/uhttpd-lua.c index 0b91b34..5158534 100644 --- a/uhttpd-lua.c +++ b/uhttpd-lua.c @@ -397,6 +397,9 @@ bool uh_lua_request(struct client *cl, lua_State *L) sleep(atoi(getenv("UHTTPD_SLEEP_ON_FORK") ?: "0")); #endif + /* do not leak parent epoll descriptor */ + uloop_done(); + /* close loose pipe ends */ close(rfd[0]); close(wfd[1]); |