Skip to content
Browse files

Update the documentroot in handler_cgi_base.

When the user has set a different Document Root in the admin, it seems
appropriate to propagate this change to the CGI subsystem handling the
request.
  • Loading branch information...
1 parent 2549350 commit 68f77c03e434ad0b6737858a8bad478d791fb0cb @skinkie skinkie committed Feb 10, 2013
Showing with 1 addition and 7 deletions.
  1. +1 −7 cherokee/handler_cgi_base.c
View
8 cherokee/handler_cgi_base.c
@@ -294,15 +294,9 @@ cherokee_handler_cgi_base_build_basic_env (
/* Document Root:
*/
- if (CONN_VSRV(conn)->evhost) {
- set_env (cgi, "DOCUMENT_ROOT",
+ set_env (cgi, "DOCUMENT_ROOT",
conn->local_directory.buf,
conn->local_directory.len);
- } else {
- set_env (cgi, "DOCUMENT_ROOT",
- CONN_VSRV(conn)->root.buf,
- CONN_VSRV(conn)->root.len);
- }
/* REMOTE_(ADDR/PORT): X-Real-IP
*/

0 comments on commit 68f77c0

Please sign in to comment.
Something went wrong with that request. Please try again.