version 1.59, 2016/04/13 12:58:13 |
version 1.60, 2016/04/14 20:38:50 |
|
|
struct query q; |
struct query q; |
char **p; /* array of available manpaths */ |
char **p; /* array of available manpaths */ |
size_t psz; /* number of available manpaths */ |
size_t psz; /* number of available manpaths */ |
|
int isquery; /* QUERY_STRING used, not PATH_INFO */ |
}; |
}; |
|
|
static void catman(const struct req *, const char *); |
static void catman(const struct req *, const char *); |
|
|
char *key, *val; |
char *key, *val; |
size_t keysz, valsz; |
size_t keysz, valsz; |
|
|
|
req->isquery = 1; |
req->q.manpath = NULL; |
req->q.manpath = NULL; |
req->q.arch = NULL; |
req->q.arch = NULL; |
req->q.sec = NULL; |
req->q.sec = NULL; |
|
|
return; |
return; |
} |
} |
|
|
if (1 == sz) { |
if (req->isquery && sz == 1) { |
/* |
/* |
* If we have just one result, then jump there now |
* If we have just one result, then jump there now |
* without any delay. |
* without any delay. |
|
|
{ |
{ |
int dir_done; |
int dir_done; |
|
|
|
req->isquery = 0; |
req->q.equal = 1; |
req->q.equal = 1; |
req->q.manpath = mandoc_strdup(path); |
req->q.manpath = mandoc_strdup(path); |
|
|