From 163ef48105ff44925a3086dc2012e27b679f5d7e Mon Sep 17 00:00:00 2001
From: DmitryTD <79697994+DmitryTD@users.noreply.github.com>
Date: Fri, 14 Jul 2023 00:46:53 +0300
Subject: [PATCH] Fix the error found by clang-tidy (#313)

auditd-reconfig.c: In function 'start_config_manager':
auditd-reconfig.c:63:42: warning: the comparison always evaluates to false
because pthread_create always returns non-negative values

Reference:https://github.com/linux-audit/audit-userspace/commit/163ef48105ff44925a3086dc2012e27b679f5d7e
Conflict:src/auditd-reconfig.c

---
 src/auditd-reconfig.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/auditd-reconfig.c b/src/auditd-reconfig.c
index 5ea9126..007ab52 100644
--- a/src/auditd-reconfig.c
+++ b/src/auditd-reconfig.c
@@ -61,7 +61,7 @@ int start_config_manager(struct auditd_event *e)
 			PTHREAD_CREATE_DETACHED);
 
 	        if (pthread_create(&config_thread, &detached,
-        	                config_thread_main, e) < 0) {
+        	                config_thread_main, e) > 0) {
                 	audit_msg(LOG_ERR,
 			"Couldn't create config thread, no config changes");
 			free(e);
-- 
2.33.0

