summaryrefslogtreecommitdiffstats
path: root/package/uhttpd/src
diff options
context:
space:
mode:
Diffstat (limited to 'package/uhttpd/src')
-rw-r--r--package/uhttpd/src/uhttpd-cgi.c3
-rw-r--r--package/uhttpd/src/uhttpd-lua.c3
2 files changed, 6 insertions, 0 deletions
diff --git a/package/uhttpd/src/uhttpd-cgi.c b/package/uhttpd/src/uhttpd-cgi.c
index ee1b80cc7..8336a1b71 100644
--- a/package/uhttpd/src/uhttpd-cgi.c
+++ b/package/uhttpd/src/uhttpd-cgi.c
@@ -365,6 +365,9 @@ bool uh_cgi_request(struct client *cl, struct path_info *pi,
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]);
diff --git a/package/uhttpd/src/uhttpd-lua.c b/package/uhttpd/src/uhttpd-lua.c
index 0b91b348f..5158534e2 100644
--- a/package/uhttpd/src/uhttpd-lua.c
+++ b/package/uhttpd/src/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]);