Skip to content
Snippets Groups Projects
Commit 92e2e3f5 authored by Jo-Philipp Wich's avatar Jo-Philipp Wich
Browse files

uhttpd: do not dispatch pipe error events, fixes use after free for cgi and lua scripts

SVN-Revision: 32644
parent bb1488e5
No related branches found
No related tags found
No related merge requests found
...@@ -573,9 +573,13 @@ static void uh_pipe_cb(struct uloop_fd *u, unsigned int events) ...@@ -573,9 +573,13 @@ static void uh_pipe_cb(struct uloop_fd *u, unsigned int events)
{ {
struct client *cl = container_of(u, struct client, pipe); struct client *cl = container_of(u, struct client, pipe);
D("SRV: Client(%d) pipe(%d) readable\n", cl->fd.fd, cl->pipe.fd); if (!u->error)
{
D("SRV: Client(%d) pipe(%d) readable\n",
cl->fd.fd, cl->pipe.fd);
uh_client_cb(&cl->fd, ULOOP_WRITE); uh_client_cb(&cl->fd, ULOOP_WRITE);
}
} }
static void uh_child_cb(struct uloop_process *p, int rv) static void uh_child_cb(struct uloop_process *p, int rv)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment