The branch main has been updated by jhb:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=09da0899551a63ce3eb841e4ce4385b6e48dd4ec

commit 09da0899551a63ce3eb841e4ce4385b6e48dd4ec
Author:     John Baldwin <[email protected]>
AuthorDate: 2026-07-27 18:09:03 +0000
Commit:     John Baldwin <[email protected]>
CommitDate: 2026-07-27 18:09:03 +0000

    getfhat: Add missing 'const' to path argument
    
    This matches the documented prototype and avoids spurious
    -Wincompatible-pointer-types-discards-qualifiers warnings when passing
    a constant pathname.
    
    Sponsored by:   AFRL, DARPA
---
 sys/kern/syscalls.master | 2 +-
 sys/sys/mount.h          | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/sys/kern/syscalls.master b/sys/kern/syscalls.master
index 4bc5385f76e7..64145f2c3e57 100644
--- a/sys/kern/syscalls.master
+++ b/sys/kern/syscalls.master
@@ -3158,7 +3158,7 @@
 564    AUE_NULL        STD {
                int getfhat(
                    int fd,
-                   _In_z_ char *path,
+                   _In_z_ const char *path,
                    _Out_ struct fhandle *fhp,
                    int flags
                );
diff --git a/sys/sys/mount.h b/sys/sys/mount.h
index dc4a49828bbe..b8b65a81369f 100644
--- a/sys/sys/mount.h
+++ b/sys/sys/mount.h
@@ -1245,7 +1245,7 @@ int       fhstat(const struct fhandle *, struct stat *);
 int    fhstatfs(const struct fhandle *, struct statfs *);
 int    fstatfs(int, struct statfs *);
 int    getfh(const char *, fhandle_t *);
-int    getfhat(int, char *, struct fhandle *, int);
+int    getfhat(int, const char *, struct fhandle *, int);
 int    getfsstat(struct statfs *, long, int);
 int    getmntinfo(struct statfs **, int);
 int    lgetfh(const char *, fhandle_t *);

Reply via email to