summaryrefslogtreecommitdiffstats
path: root/net/fakeidentd/patches/100-use-standard-boolean-type.patch
blob: dd7e2b086a83ba394dd86bb3f2be09163fbbeda6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Hauke Mehrtens <hauke@hauke-m.de>
Date: Sat, 28 Nov 2026 02:40:03 +0100
Subject: [PATCH] Use the standard boolean type

GCC 15 defaults to C23, in which bool, false and true are keywords.
Use stdbool.h for pre-C23 C compilers. C++ has its own boolean type.

--- a/fakeidentd-2.6.c
+++ b/fakeidentd-2.6.c
@@ -241,7 +241,7 @@ static const char ident_substr[] = " : U
 static const int ident_substr_len = sizeof ident_substr - 1;
 
 #if !defined __cplusplus
-typedef enum { false = 0, true = 1 } bool;
+#include <stdbool.h>
 #endif
 
 #if (__GNUC__ >= 3)