summaryrefslogtreecommitdiffstats
path: root/fsck/fsck.c
diff options
context:
space:
mode:
authorSami Kerola2011-02-24 20:15:43 +0100
committerKarel Zak2011-03-08 11:49:55 +0100
commite0eadc0dc5566577cd99cc91aa894178af6bf123 (patch)
tree84ee4017f12f73046ae62ad448f503ce2f6bf6c5 /fsck/fsck.c
parentman page syntax fixes (diff)
downloadkernel-qcow2-util-linux-e0eadc0dc5566577cd99cc91aa894178af6bf123.tar.gz
kernel-qcow2-util-linux-e0eadc0dc5566577cd99cc91aa894178af6bf123.tar.xz
kernel-qcow2-util-linux-e0eadc0dc5566577cd99cc91aa894178af6bf123.zip
fsck: fix clang compiler warning
fsck.c:874:22: warning: format string is not a string literal (potentially insecure) [-Wformat-security] errx(EXIT_USAGE, _(fs_type_syntax_error)); ^~~~~~~~~~~~~~~~~~~~~~~ The issue was introduced in my commit 0a09eb4e, sorry. Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'fsck/fsck.c')
-rw-r--r--fsck/fsck.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/fsck/fsck.c b/fsck/fsck.c
index effc866f3..0d5fedac2 100644
--- a/fsck/fsck.c
+++ b/fsck/fsck.c
@@ -819,10 +819,6 @@ struct fs_type_compile {
#define FS_TYPE_OPT 1
#define FS_TYPE_NEGOPT 2
-static const char *fs_type_syntax_error =
-N_("Either all or none of the filesystem types passed to -t must be prefixed\n"
- "with 'no' or '!'.\n");
-
static void compile_fs_type(char *fs_type, struct fs_type_compile *cmp)
{
char *cp, *list, *s;
@@ -871,7 +867,9 @@ static void compile_fs_type(char *fs_type, struct fs_type_compile *cmp)
}
if ((negate && !cmp->negate) ||
(!negate && cmp->negate)) {
- errx(EXIT_USAGE, _(fs_type_syntax_error));
+ errx(EXIT_USAGE,
+ _("Either all or none of the filesystem types passed to -t must be prefixed\n"
+ "with 'no' or '!'."));
}
}
#if 0