The branch main has been updated by rmacklem:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=2409231121ba6fc0ce5c16dc070b564c613c8fc5

commit 2409231121ba6fc0ce5c16dc070b564c613c8fc5
Author:     Rick Macklem <[email protected]>
AuthorDate: 2023-08-10 19:50:35 +0000
Commit:     Rick Macklem <[email protected]>
CommitDate: 2023-08-10 19:50:35 +0000

    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:    [email protected]
    Reviewed by:    theraven, karels (prev version), kevans (prev version)
    Differential Revision:  https://reviews.freebsd.org/D41265
---
 usr.sbin/mountd/mountd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

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;

Reply via email to