Commit Diff


commit - ac15152e219bed9c7f41007a39c3cbce83ea9386
commit + 60594467968767d3e25ac41c9b0ace2851c9fad5
blob - 388afd09354459f0e51fb97f0f90691c05674609
blob + 449626bea5142dd28150d6b7d4f526712840e040
--- gotwebd/gotwebd.c
+++ gotwebd/gotwebd.c
@@ -343,8 +343,8 @@ main(int argc, char **argv)
 		setproctitle("sockets");
 		log_procinit("sockets");
 
-		if (chroot(pw->pw_dir) == -1)
-			fatal("chroot %s", pw->pw_dir);
+		if (chroot(env->httpd_chroot) == -1)
+			fatal("chroot %s", env->httpd_chroot);
 		if (chdir("/") == -1)
 			fatal("chdir /");
 		if (setgroups(1, &pw->pw_gid) == -1 ||