Module Name: src
Committed By: snj
Date: Mon Dec 4 19:44:13 UTC 2017
Modified Files:
src/libexec/httpd [netbsd-8]: cgi-bozo.c
Log Message:
Pull up following revision(s) (requested by martin in ticket #409):
libexec/httpd/cgi-bozo.c: revision 1.39
PR bin/52194: bozohttpd fails to exec scripts via the -C mechanism
sometimes with EFAULT due to not NULL terminated environment.
To generate a diff of this commit:
cvs rdiff -u -r1.37 -r1.37.4.1 src/libexec/httpd/cgi-bozo.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/libexec/httpd/cgi-bozo.c
diff -u src/libexec/httpd/cgi-bozo.c:1.37 src/libexec/httpd/cgi-bozo.c:1.37.4.1
--- src/libexec/httpd/cgi-bozo.c:1.37 Tue Jan 31 14:36:09 2017
+++ src/libexec/httpd/cgi-bozo.c Mon Dec 4 19:44:13 2017
@@ -1,4 +1,4 @@
-/* $NetBSD: cgi-bozo.c,v 1.37 2017/01/31 14:36:09 mrg Exp $ */
+/* $NetBSD: cgi-bozo.c,v 1.37.4.1 2017/12/04 19:44:13 snj Exp $ */
/* $eterna: cgi-bozo.c,v 1.40 2011/11/18 09:21:15 mrg Exp $ */
@@ -587,6 +587,8 @@ bozo_process_cgi(bozo_httpreq_t *request
bozoerr(httpd, 1, "child socketpair failed: %s",
strerror(errno));
+ *curenvp = 0;
+
/*
* We create 2 procs: one to become the CGI, one read from
* the CGI and output to the network, and this parent will