git: 42b117a4bd10 - main - gpioevents: Fix build with newer Clang
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 02 Mar 2024 15:39:12 UTC
The branch main has been updated by emaste:
URL: https://cgit.FreeBSD.org/src/commit/?id=42b117a4bd104246589149fa9f7b9b7ddc144f23
commit 42b117a4bd104246589149fa9f7b9b7ddc144f23
Author: John F. Carr <jfc@mit.edu>
AuthorDate: 2024-03-02 15:38:04 +0000
Commit: Ed Maste <emaste@FreeBSD.org>
CommitDate: 2024-03-02 15:38:04 +0000
gpioevents: Fix build with newer Clang
PR: 277422
---
tools/test/gpioevents/Makefile | 2 ++
tools/test/gpioevents/gpioevents.c | 4 ++--
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/tools/test/gpioevents/Makefile b/tools/test/gpioevents/Makefile
index 7976bd03174a..4bc4422ae333 100644
--- a/tools/test/gpioevents/Makefile
+++ b/tools/test/gpioevents/Makefile
@@ -8,4 +8,6 @@ MK_MAN= no
BINDIR= /usr/bin
+CWARNFLAGS += -Wno-gnu-folding-constant
+
.include <bsd.prog.mk>
diff --git a/tools/test/gpioevents/gpioevents.c b/tools/test/gpioevents/gpioevents.c
index f1bc8e8ee224..43bad610cb68 100644
--- a/tools/test/gpioevents/gpioevents.c
+++ b/tools/test/gpioevents/gpioevents.c
@@ -61,7 +61,7 @@ sigio_handler(int sig __unused){
}
static void
-usage()
+usage(void)
{
fprintf(stderr, "usage: %s [-f ctldev] [-m method] [-s] [-n] [-S] [-u]"
"[-t timeout] [-d delay-usec] pin intr-config pin-mode [pin intr-config pin-mode ...]\n\n",
@@ -152,7 +152,7 @@ print_poll_events(short event)
}
static void
-calc_utc_offset()
+calc_utc_offset(void)
{
struct timespec monotime, utctime;