summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2012-10-04 14:19:39 +0200
committerFelix Fietkau <nbd@openwrt.org>2012-10-04 14:19:39 +0200
commitb20ffa963c767ea53acb448354bdf13187ebe644 (patch)
tree3854cdebd80ad482986857b549b1fb078cda10aa
parentdea7e0275b4bb7604ed7d79c8f6f8f91804de8a6 (diff)
downloaduhttpd-b20ffa963c767ea53acb448354bdf13187ebe644.tar.gz
add more missing ifdefs
-rw-r--r--uhttpd.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/uhttpd.c b/uhttpd.c
index f6d6756..ebaa019 100644
--- a/uhttpd.c
+++ b/uhttpd.c
@@ -578,6 +578,7 @@ static void uh_socket_cb(struct uloop_fd *u, unsigned int events)
uh_client_cb(cl, ULOOP_READ);
}
+#if defined(HAVE_CGI) || defined(HAVE_LUA) || defined(HAVE_UBUS)
static void uh_child_cb(struct uloop_process *p, int rv)
{
struct client *cl = container_of(p, struct client, proc);
@@ -617,6 +618,7 @@ static void uh_timeout_cb(struct uloop_timeout *t)
uloop_timeout_set(&cl->timeout, 1000);
}
}
+#endif
static void uh_client_cb(struct client *cl, unsigned int events)
{
@@ -700,6 +702,7 @@ static void uh_client_cb(struct client *cl, unsigned int events)
}
/* request handler spawned a child, register handler */
+#if defined(HAVE_CGI) || defined(HAVE_LUA) || defined(HAVE_UBUS)
if (cl->proc.pid)
{
D("SRV: Client(%d) child(%d) spawned\n", cl->fd.fd, cl->proc.pid);
@@ -710,6 +713,7 @@ static void uh_client_cb(struct client *cl, unsigned int events)
cl->timeout.cb = uh_timeout_cb;
uloop_timeout_set(&cl->timeout, conf->script_timeout * 1000);
}
+#endif
/* header processing complete */
D("SRV: Client(%d) dispatched\n", cl->fd.fd);