aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/mountd/mountd.c
diff options
context:
space:
mode:
authorRick Macklem <rmacklem@FreeBSD.org>2023-08-10 19:50:35 +0000
committerRick Macklem <rmacklem@FreeBSD.org>2023-08-10 19:50:35 +0000
commit2409231121ba6fc0ce5c16dc070b564c613c8fc5 (patch)
tree365a5dd713219cea9dc6647be51d89fcec4895b4 /usr.sbin/mountd/mountd.c
parent9795f14ec40acbab93aabedf05d70e0256ce9bf5 (diff)
downloadsrc-2409231121ba6fc0ce5c16dc070b564c613c8fc5.tar.gz
src-2409231121ba6fc0ce5c16dc070b564c613c8fc5.zip
mountd: Fix type of signal variable
Without this patch got_sighup(), which is the SIGHUP handler, would set a variable of type int. This would appear to be incorrect, although it has worked reliably. This patch changes the type to "_Atomic(int)", which appears to be all that is needed to correct it. Reported by: pen@lysator.lui.se Reviewed by: theraven, karels (prev version), kevans (prev version) Differential Revision: https://reviews.freebsd.org/D41265
Diffstat (limited to 'usr.sbin/mountd/mountd.c')
-rw-r--r--usr.sbin/mountd/mountd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/mountd/mountd.c b/usr.sbin/mountd/mountd.c
index 1924284bb93a..22dfcc3c1abb 100644
--- a/usr.sbin/mountd/mountd.c
+++ b/usr.sbin/mountd/mountd.c
@@ -290,7 +290,7 @@ static int resvport_only = 1;
static int nhosts = 0;
static int dir_only = 1;
static int dolog = 0;
-static int got_sighup = 0;
+static _Atomic(int) got_sighup = 0;
static int xcreated = 0;
static char *svcport_str = NULL;