From: Markus Elfring Date: Tue, 2 Jul 2019 18:27:32 +0000 (+0200) Subject: apparmor: Replace two seq_printf() calls by seq_puts() in aa_label_seq_xprint() X-Git-Tag: v5.8-rc1~102^2~16 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=278de07ef84a4356a3b166dc17751abc03abca67;p=thirdparty%2Fkernel%2Flinux.git apparmor: Replace two seq_printf() calls by seq_puts() in aa_label_seq_xprint() Two strings which did not contain a data format specification should be put into a sequence. Thus use the corresponding function “seq_puts”. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Signed-off-by: John Johansen --- diff --git a/security/apparmor/label.c b/security/apparmor/label.c index 470693239e64f..bb34094421c45 100644 --- a/security/apparmor/label.c +++ b/security/apparmor/label.c @@ -1749,13 +1749,13 @@ void aa_label_seq_xprint(struct seq_file *f, struct aa_ns *ns, AA_DEBUG("label print error"); return; } - seq_printf(f, "%s", str); + seq_puts(f, str); kfree(str); } else if (display_mode(ns, label, flags)) seq_printf(f, "%s (%s)", label->hname, label_modename(ns, label, flags)); else - seq_printf(f, "%s", label->hname); + seq_puts(f, label->hname); } void aa_label_xprintk(struct aa_ns *ns, struct aa_label *label, int flags,