From bc12225c65548a8d43fee9259d4e4eb27f4c51ab Mon Sep 17 00:00:00 2001 From: Namhyung Kim Date: Tue, 23 Apr 2024 22:24:24 -0700 Subject: [PATCH] autoargs: Add a prototype for fchmodat(3) It seems fchmodat() was added in POSIX 2008. Add that to the prototype. int fchmodat(int dirfd, const char *pathname, oct_mode_t mode, int flags); Signed-off-by: Namhyung Kim --- misc/prototypes.h | 1 + utils/auto-args.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/misc/prototypes.h b/misc/prototypes.h index c5e7484c8..f017e98a4 100644 --- a/misc/prototypes.h +++ b/misc/prototypes.h @@ -501,6 +501,7 @@ int lstat(const char *pathname, void *statbuf); int chmod(const char *pathname, oct_mode_t mode); int fchmod(int fd, oct_mode_t mode); +int fchmodat(int dirfd, const char *pathname, oct_mode_t mode, int flags); void umask(oct_mode_t mask); int creat(const char *file, oct_mode_t mode); diff --git a/utils/auto-args.h b/utils/auto-args.h index d7eecf645..c25c37ba6 100644 --- a/utils/auto-args.h +++ b/utils/auto-args.h @@ -232,6 +232,7 @@ static char *auto_args_list = "lstat@arg1/s,arg2/p;" "chmod@arg1/s,arg2/o;" "fchmod@arg1/d32,arg2/o;" + "fchmodat@arg1/d32,arg2/s,arg3/o,arg4/d32;" "umask@arg1/o;" "creat@arg1/s,arg2/o;" "creat64@arg1/s,arg2/o;" @@ -451,6 +452,7 @@ static char *auto_retvals_list = "lstat@retval/d32;" "chmod@retval/d32;" "fchmod@retval/d32;" + "fchmodat@retval/d32;" "creat@retval/d32;" "creat64@retval/d32;" "isatty@retval/d32;"