[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190614202843.26941-31-sashal@kernel.org>
Date: Fri, 14 Jun 2019 16:28:15 -0400
From: Sasha Levin <sashal@...nel.org>
To: linux-kernel@...r.kernel.org, stable@...r.kernel.org
Cc: Alakesh Haloi <alakesh.haloi@...il.com>,
Peter Xu <peterx@...hat.com>,
Mike Rapoport <rppt@...ux.ibm.com>,
Shuah Khan <skhan@...uxfoundation.org>,
Sasha Levin <sashal@...nel.org>,
linux-kselftest@...r.kernel.org
Subject: [PATCH AUTOSEL 5.1 31/59] userfaultfd: selftest: fix compiler warning
From: Alakesh Haloi <alakesh.haloi@...il.com>
[ Upstream commit 98a13a8d253999cf25eb16d901c35fbd2a8455c4 ]
Fixes following compiler warning
userfaultfd.c: In function ‘usage’:
userfaultfd.c:126:2: warning: format not a string literal and no format
arguments [-Wformat-security]
fprintf(stderr, examples);
Signed-off-by: Alakesh Haloi <alakesh.haloi@...il.com>
Reviewed-by: Peter Xu <peterx@...hat.com>
Reviewed-by: Mike Rapoport <rppt@...ux.ibm.com>
Signed-off-by: Shuah Khan <skhan@...uxfoundation.org>
Signed-off-by: Sasha Levin <sashal@...nel.org>
---
tools/testing/selftests/vm/userfaultfd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/testing/selftests/vm/userfaultfd.c b/tools/testing/selftests/vm/userfaultfd.c
index 5d1db824f73a..b3e6497b080c 100644
--- a/tools/testing/selftests/vm/userfaultfd.c
+++ b/tools/testing/selftests/vm/userfaultfd.c
@@ -123,7 +123,7 @@ static void usage(void)
fprintf(stderr, "Supported <test type>: anon, hugetlb, "
"hugetlb_shared, shmem\n\n");
fprintf(stderr, "Examples:\n\n");
- fprintf(stderr, examples);
+ fprintf(stderr, "%s", examples);
exit(1);
}
--
2.20.1
Powered by blists - more mailing lists