summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cgi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cgi.c b/cgi.c
index ce7e1242..f9249c0e 100644
--- a/cgi.c
+++ b/cgi.c
@@ -1026,7 +1026,7 @@ main(void)
if (*path != '\0') {
parse_path_info(&req, path);
- if (access(path, F_OK) == -1)
+ if (req.q.manpath == NULL || access(path, F_OK) == -1)
path = "";
} else if ((querystring = getenv("QUERY_STRING")) != NULL)
parse_query_string(&req, querystring);