From 312e06c24f3a7f8ef7ea43ecd10f04d80c623f14 Mon Sep 17 00:00:00 2001 From: Arshad Hussain Date: Tue, 6 Aug 2019 18:11:52 +0530 Subject: [PATCH 1/1] LU-6142 tests: Fix style issues for munlink.c This patch fixes issues reported by checkpatch for file lustre/tests/munlink.c Test-Parameters: trivial Signed-off-by: Arshad Hussain Change-Id: I1722de906c529045fc9a2c8edc877d695840677d Reviewed-on: https://review.whamcloud.com/35912 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Shaun Tancheff Reviewed-by: Petros Koutoupis Reviewed-by: Ben Evans Reviewed-by: Oleg Drokin --- lustre/tests/munlink.c | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/lustre/tests/munlink.c b/lustre/tests/munlink.c index b296bdb..80778a7 100644 --- a/lustre/tests/munlink.c +++ b/lustre/tests/munlink.c @@ -36,27 +36,27 @@ #include #include -int main(int argc, char ** argv) +int main(int argc, char **argv) { - int rc = 0, i; + int rc = 0, i; - if (argc < 2) { - printf("Usage %s filename {filename ...}\n", argv[0]); - return 1; - } + if (argc < 2) { + printf("Usage %s filename {filename ...}\n", argv[0]); + return 1; + } - for (i = 1; i < argc; i++) { - rc = unlink(argv[i]); - if (rc) { - printf("unlink(%s): %s ", argv[i], strerror(errno)); - rc = access(argv[i], F_OK); - if (rc && errno == ENOENT) - printf("(unlinked anyways)\n"); - else if (rc == 0) - printf("(still exists)\n"); - else - printf("(%s looking up)\n", strerror(errno)); - } - } - return rc; + for (i = 1; i < argc; i++) { + rc = unlink(argv[i]); + if (rc) { + printf("unlink(%s): %s ", argv[i], strerror(errno)); + rc = access(argv[i], F_OK); + if (rc && errno == ENOENT) + printf("(unlinked anyways)\n"); + else if (rc == 0) + printf("(still exists)\n"); + else + printf("(%s looking up)\n", strerror(errno)); + } + } + return rc; } -- 1.8.3.1