diff options
author | Vincent Douillet <vincent@vdouillet.fr> | 2024-12-26 18:13:42 +0100 |
---|---|---|
committer | Vincent Douillet <vincent@vdouillet.fr> | 2024-12-27 15:21:14 +0100 |
commit | fddc6610d724dc08433ea99a98406d76c47e9df1 (patch) | |
tree | 6e96ffbedbd2d7ab119345a9cc367b6869236819 /main.c | |
parent | 1bcf812973335b424655b272eb831d4eb8f059fc (diff) |
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 12 |
1 files changed, 4 insertions, 8 deletions
@@ -62,7 +62,6 @@ main(void) char *data_dir; enum kcgi_err parse_err; struct kreq r; - struct http_ret ret; if (kutil_openlog(LOG_FILE) == 0) http_exit(NULL, KHTTP_500, "Unable to open %s", LOG_FILE); @@ -97,16 +96,16 @@ main(void) case PAGE_BROWSE: if (r.mime != KMIME_TEXT_HTML) http_exit(&r, KHTTP_406, NULL); /* Not Acceptable */ - ret = browse(&r); + browse(&r); break; case PAGE_DOWNLOAD: - ret = download(&r); + download(&r); break; case PAGE_UPLOAD: - ret = upload(&r); + upload(&r); break; case PAGE_DELETE: - ret = del(&r); + del(&r); break; default: http_exit(&r, KHTTP_404, NULL); @@ -114,8 +113,5 @@ main(void) khttp_free(&r); - if (ret.code >= KHTTP_400) - http_exit(&r, ret.code, ret.message); - return EXIT_SUCCESS; } |