chdir to the vhost root before exec'ing the CGI script

This commit is contained in:
Omar Polo 2021-01-24 09:15:05 +00:00
parent e7a2a99b5a
commit 05748e49fe

2
ex.c
View File

@ -237,6 +237,8 @@ launch_cgi(const char *spath, const char *relpath, const char *query,
safe_setenv("TLS_CLIENT_HASH", chash);
}
fchdir(vhost->dir);
execvp(ex, argv);
goto childerr;
}