]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
shared/microhttp-util: silence gcc warning
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Sun, 5 Jun 2022 08:24:15 +0000 (10:24 +0200)
committerFrantisek Sumsal <frantisek@sumsal.cz>
Sun, 5 Jun 2022 15:57:39 +0000 (15:57 +0000)
../src/journal-remote/microhttpd-util.c: In function ‘check_permissions’:
../src/journal-remote/microhttpd-util.c:301:5: error: function might be candidate for attribute ‘noreturn’ [-Werror=suggest-attribute=noreturn]
  301 | int check_permissions(struct MHD_Connection *connection, int *code, char **hostname) {
      |     ^~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

Fixes #23630.

src/journal-remote/microhttpd-util.c

index 48e4b1414cb38a2a20f849ce72094ae8b97b5c33..271e304273b1a3ef9538d309eb8ac5e613d0f0cd 100644 (file)
@@ -298,7 +298,7 @@ int check_permissions(struct MHD_Connection *connection, int *code, char **hostn
 }
 
 #else
-int check_permissions(struct MHD_Connection *connection, int *code, char **hostname) {
+_noreturn_ int check_permissions(struct MHD_Connection *connection, int *code, char **hostname) {
         assert_not_reached();
 }