summaryrefslogtreecommitdiffstats
path: root/cgi.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2016-04-14 23:48:48 +0000
committerIngo Schwarze <schwarze@openbsd.org>2016-04-14 23:48:48 +0000
commit40ae11d5b5fea96050cf3e796db9a26e9b7512a4 (patch)
tree0a39b66eab19102881909dde9ae29b7399aa0507 /cgi.c
parentcf94c4a573b971dabddb91cc2ecec79767a861c3 (diff)
downloadmandoc-40ae11d5b5fea96050cf3e796db9a26e9b7512a4.tar.gz
for .Xr links, use short PATH_INFO style URIs
Diffstat (limited to 'cgi.c')
-rw-r--r--cgi.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/cgi.c b/cgi.c
index b7773679..4de5a117 100644
--- a/cgi.c
+++ b/cgi.c
@@ -816,12 +816,8 @@ format(const struct req *req, const char *file)
memset(&conf, 0, sizeof(conf));
conf.fragment = 1;
usepath = strcmp(req->q.manpath, req->p[0]);
- mandoc_asprintf(&conf.man, "/%s?query=%%N&sec=%%S%s%s%s%s",
- scriptname,
- req->q.arch ? "&arch=" : "",
- req->q.arch ? req->q.arch : "",
- usepath ? "&manpath=" : "",
- usepath ? req->q.manpath : "");
+ mandoc_asprintf(&conf.man, "/%s%s%%N.%%S",
+ usepath ? req->q.manpath : "", usepath ? "/" : "");
mparse_result(mp, &man, NULL);
if (man == NULL) {