OpenAFS Master Repository branch, master, updated. openafs-devel-1_9_2-218-gbf64c84
Gerrit Code Review
gerrit@openafs.org
Tue, 29 Apr 2025 00:42:10 -0400
The following commit has been merged in the master branch:
commit bf64c84058493ee6fe2b1b2fb27b73787aaed318
Author: Cheyenne Wills <cwills@sinenomine.net>
Date: Thu Apr 24 13:21:12 2025 -0600
lwp: Replace the typedefed bool datatype with int
A new C standard (C23) is coming out and newer versions of C compilers
(e.g. gcc 15) are using the new standard (or an extension of that
standard) as their default. The C23 standard has added a native C data
type `bool`. This causes a build error when code tries to use
a typedef to define a `bool` data type:
iomgr.c:50:23: error: ‘bool’ cannot be defined via ‘typedef’
50 | typedef unsigned char bool;
| ^~~~
iomgr.c:50:23: note: ‘bool’ is a keyword with ‘-std=c23’ onwards
iomgr.c:50:1: warning: useless type name in empty declaration
50 | typedef unsigned char bool;
There are just a few locations where `bool` is used as a data type.
Replace the use of the `bool` data type with an `int`.
Note: This problem occurred on Fedora 42 which comes with gcc 15.
Change-Id: Ib29d8ce80fee6938258bcda1de4c01459ea75049
Reviewed-on: https://gerrit.openafs.org/16369
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Andrew Deason <adeason@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/lwp/iomgr.c | 5 ++---
src/lwp/timer.c | 3 +--
2 files changed, 3 insertions(+), 5 deletions(-)
--
OpenAFS Master Repository