| Fix double printing notfounderr and fix notfound on not allowed dir trav. - geo… | |
| git clone git://bitreich.org/geomyidae/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfri… | |
| Log | |
| Files | |
| Refs | |
| Tags | |
| README | |
| LICENSE | |
| --- | |
| commit 32c1854864ce91a873e607659294eda9012411e6 | |
| parent e35d04d03d5c4c8ddc88e73c5c3f092e3d309a40 | |
| Author: Christoph Lohmann <[email protected]> | |
| Date: Mon, 21 Aug 2023 11:37:44 +0200 | |
| Fix double printing notfounderr and fix notfound on not allowed dir trav. | |
| Diffstat: | |
| M main.c | 2 ++ | |
| 1 file changed, 2 insertions(+), 0 deletions(-) | |
| --- | |
| diff --git a/main.c b/main.c | |
| @@ -329,6 +329,7 @@ dothegopher: | |
| dprintf(sock, notfounderr, recvc); | |
| if (loglvl & ERRORS) | |
| logentry(clienth, clientp, recvc, "not found"); | |
| + return; | |
| } | |
| if (stat(rpath, &dir) != -1) { | |
| /* | |
| @@ -426,6 +427,7 @@ dothegopher: | |
| } | |
| } else { | |
| if (pathfallthrough && S_ISDIR(dir.st_mode)) { | |
| + dprintf(sock, notfounderr, recvc); | |
| if (loglvl & ERRORS) { | |
| logentry(clienth, clientp, recvc, | |
| "directory listing in traversal not al… |