From 580ba924a41c8116e3b5a7e5e5689f700526c36c Mon Sep 17 00:00:00 2001 From: ejurgensen Date: Tue, 25 Apr 2023 23:04:44 +0200 Subject: [PATCH] [httpd] Remove needless test (always true) --- src/httpd.c | 2 +- src/httpd_internal.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/httpd.c b/src/httpd.c index 8a5087bf..66354385 100644 --- a/src/httpd.c +++ b/src/httpd.c @@ -273,7 +273,7 @@ modules_search(const char *path) for (ptr = httpd_modules; *ptr; ptr++) { m = *ptr; - if (!m->subpaths || !m->request) + if (!m->request) continue; for (test = m->subpaths; *test && !is_found; test++) diff --git a/src/httpd_internal.h b/src/httpd_internal.h index 0157601e..60b45e91 100644 --- a/src/httpd_internal.h +++ b/src/httpd_internal.h @@ -120,7 +120,7 @@ struct httpd_module // Null-terminated list of URL subpath that the module accepts e.g., /subpath/morepath/file.mp3 const char *subpaths[16]; - // Null-terminated list of URL fullparhs that the module accepts e.g., /fullpath + // Null-terminated list of URL fullpaths that the module accepts e.g., /fullpath const char *fullpaths[16]; // Pointer to the module's handler definitions struct httpd_uri_map *handlers;