aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/acl
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2020-06-16 08:40:53 -0400
committerDave Wallace <dwallacelf@gmail.com>2020-06-16 17:32:17 +0000
commit1af730d0dfbb91475c6808ed579494d3d223b724 (patch)
treec6eabf52103e066dedb2eafc952399c996523593 /src/plugins/acl
parentcea46522e79637f6ec37c03ec3fbeb87b160a378 (diff)
misc: fix sonarclound warnings
Type: fix Ticket: VPP-1888 Signed-off-by: Dave Barach <dave@barachs.net> Change-Id: I9c2fb926a5e010658088a74051c8c3462ff61734
Diffstat (limited to 'src/plugins/acl')
-rw-r--r--src/plugins/acl/acl_test.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/plugins/acl/acl_test.c b/src/plugins/acl/acl_test.c
index e559f3acc9c..c139b325568 100644
--- a/src/plugins/acl/acl_test.c
+++ b/src/plugins/acl/acl_test.c
@@ -615,10 +615,13 @@ api_acl_add_replace_from_file (vat_main_t * vam)
break;
}
+ if (file_name == NULL)
+ goto done;
+
fd = open(file_name, O_RDONLY);
if (fd < 0)
{
- clib_warning("Could not open file '%s'");
+ clib_warning("Could not open file '%s'", file_name);
goto done;
}