From 832ee3d79e36b1e49b07ec841aa1497088e1729b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Christian=20G=C3=B6ttsche?= Date: Tue, 21 Feb 2023 15:28:45 +0100 Subject: [PATCH] libmount: declare array of LSM options const --- libmount/src/context_mount.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libmount/src/context_mount.c b/libmount/src/context_mount.c index 7491ec205b..7b897345c6 100644 --- a/libmount/src/context_mount.c +++ b/libmount/src/context_mount.c @@ -29,9 +29,9 @@ #include "strutils.h" #if defined(HAVE_LIBSELINUX) || defined(HAVE_SMACK) -static int is_option(const char *name, const char **names) +static int is_option(const char *name, const char *const *names) { - const char **p; + const char *const *p; for (p = names; p && *p; p++) { if (strcmp(name, *p) == 0) @@ -141,7 +141,7 @@ static int fix_optstr(struct libmnt_context *cxt) /* Fix SELinux contexts */ if (se_rem || se_fix) { - static const char *selinux_options[] = { + static const char *const selinux_options[] = { "context", "fscontext", "defcontext", @@ -184,7 +184,7 @@ static int fix_optstr(struct libmnt_context *cxt) if (access("/sys/fs/smackfs", F_OK) != 0) { struct libmnt_iter itr; - static const char *smack_options[] = { + static const char *const smack_options[] = { "smackfsdef", "smackfsfloor", "smackfshat", -- 2.47.2