[PATCH v1] remove unused fn audit_add_dir and decl audit_rule_syscall_data

Steve Grubb sgrubb at redhat.com
Thu Oct 28 21:13:53 UTC 2021


On Thursday, October 28, 2021 3:48:39 PM EDT Richard Guy Briggs wrote:
> The former has no activity since pre-1.7.4, no in-tree users and no
> manpage, so remove it.  The latter is only used locally, remove prototype.

The purpose for this is lost in time. Applied.

Thanks,
-Steve

> Signed-off-by: Richard Guy Briggs <rgb at redhat.com>
> ---
>  lib/libaudit.c | 5 -----
>  lib/libaudit.h | 2 --
>  2 files changed, 7 deletions(-)
> 
> diff --git a/lib/libaudit.c b/lib/libaudit.c
> index bf3c22bc7beb..54e276156ef0 100644
> --- a/lib/libaudit.c
> +++ b/lib/libaudit.c
> @@ -742,11 +742,6 @@ int audit_add_watch(struct audit_rule_data **rulep,
> const char *path) return audit_add_watch_dir(AUDIT_WATCH, rulep, path);
>  }
> 
> -int audit_add_dir(struct audit_rule_data **rulep, const char *path)
> -{
> -	return audit_add_watch_dir(AUDIT_DIR, rulep, path);
> -}
> -
>  int audit_add_watch_dir(int type, struct audit_rule_data **rulep,
>  			const char *path)
>  {
> diff --git a/lib/libaudit.h b/lib/libaudit.h
> index 6bd1758eb9d3..4e532177aa11 100644
> --- a/lib/libaudit.h
> +++ b/lib/libaudit.h
> @@ -656,7 +656,6 @@ extern int audit_request_signal_info(int fd);
>  /* AUDIT_WATCH */
>  extern int audit_update_watch_perms(struct audit_rule_data *rule, int
> perms); extern int audit_add_watch(struct audit_rule_data **rulep, const
> char *path); -extern int audit_add_dir(struct audit_rule_data **rulep,
> const char *path); extern int audit_add_watch_dir(int type, struct
> audit_rule_data **rulep, const char *path);
>  extern int audit_trim_subtrees(int fd);
> @@ -701,7 +700,6 @@ extern int audit_log_user_command(int audit_fd, int
> type, const char *command, extern struct audit_rule_data
> *audit_rule_create_data(void);
>  /* Initializes an existing audit_rule_data struct */
>  extern void audit_rule_init_data(struct audit_rule_data *rule);
> -extern int audit_rule_syscall_data(struct audit_rule_data *rule, int
> scall); extern int audit_rule_syscallbyname_data(struct audit_rule_data
> *rule, const char *scall);
>  /* Note that the following function takes a **, where
> audit_rule_fieldpair()







More information about the Linux-audit mailing list