empty request should works all the time, not only when in virtualhost
This commit is contained in:
parent
fbacb35170
commit
7b0686bdfa
1 changed files with 3 additions and 3 deletions
2
main.c
2
main.c
|
@ -435,10 +435,10 @@ main(int argc, char **argv)
|
||||||
* hostname directory gemini://foobar/hello will look for
|
* hostname directory gemini://foobar/hello will look for
|
||||||
* chroot_path/foobar/hello
|
* chroot_path/foobar/hello
|
||||||
*/
|
*/
|
||||||
if (virtualhost) {
|
|
||||||
if (strlen(uri) == 0) {
|
if (strlen(uri) == 0) {
|
||||||
estrlcpy(uri, "/index.gmi", sizeof(uri));
|
estrlcpy(uri, "/index.gmi", sizeof(uri));
|
||||||
}
|
}
|
||||||
|
if (virtualhost) {
|
||||||
char tmp[PATH_MAX] = {'\0'};
|
char tmp[PATH_MAX] = {'\0'};
|
||||||
estrlcpy(tmp, hostname, sizeof(tmp));
|
estrlcpy(tmp, hostname, sizeof(tmp));
|
||||||
estrlcat(tmp, uri, sizeof(tmp));
|
estrlcat(tmp, uri, sizeof(tmp));
|
||||||
|
|
Loading…
Reference in a new issue