From 423a614a6d6afcfcc36aacfd405a3e7e7add8deb Mon Sep 17 00:00:00 2001 From: Michael Weghorn Date: Tue, 15 Oct 2024 15:30:06 +0200 Subject: [PATCH] Return something in non-void function (#70) Return NULL in `background_thread`, as the return type is `gpointer`. Fixes this error in a `-Wall -Werror` build: cpdb-frontend.c: In function 'background_thread': cpdb-frontend.c:465:1: error: control reaches end of non-void function [-Werror=return-type] 465 | } | ^ --- cpdb/cpdb-frontend.c | 1 + 1 file changed, 1 insertion(+) diff --git a/cpdb/cpdb-frontend.c b/cpdb/cpdb-frontend.c index 92337c8..72833a9 100644 --- a/cpdb/cpdb-frontend.c +++ b/cpdb/cpdb-frontend.c @@ -461,6 +461,7 @@ gpointer background_thread(gpointer user_data) { if (f->stop_flag) break; cpdbActivateBackends(f); } + return NULL; } // Start the background thread