misc: clib_unix_warning usage error
Type: fix
Signed-off-by: jiangxiaoming <jiangxiaoming@outlook.com>
Change-Id: Ibc4e961388d0976b55b9b936d6a37d36cddab5fe
diff --git a/src/svm/ssvm.c b/src/svm/ssvm.c
index c030650..d2788e8 100644
--- a/src/svm/ssvm.c
+++ b/src/svm/ssvm.c
@@ -231,14 +231,14 @@
if (memfd->fd == CLIB_MEM_ERROR)
{
- clib_unix_warning (0, "failed to create memfd");
+ clib_unix_warning ("failed to create memfd");
return SSVM_API_ERROR_CREATE_FAILURE;
}
log2_page_size = clib_mem_get_fd_log2_page_size (memfd->fd);
if (log2_page_size == 0)
{
- clib_unix_warning (0, "cannot determine page size");
+ clib_unix_warning ("cannot determine page size");
return SSVM_API_ERROR_CREATE_FAILURE;
}
@@ -246,7 +246,7 @@
if ((ftruncate (memfd->fd, n_pages << log2_page_size)) == -1)
{
- clib_unix_warning (0, "memfd ftruncate failure");
+ clib_unix_warning ("memfd ftruncate failure");
return SSVM_API_ERROR_CREATE_FAILURE;
}
@@ -367,7 +367,7 @@
log2_page_size = clib_mem_get_log2_page_size ();
if (log2_page_size == 0)
{
- clib_unix_warning (0, "cannot determine page size");
+ clib_unix_warning ("cannot determine page size");
return SSVM_API_ERROR_CREATE_FAILURE;
}
diff --git a/src/vpp/api/vpp_get_metrics.c b/src/vpp/api/vpp_get_metrics.c
index 04036bc..41d2393 100644
--- a/src/vpp/api/vpp_get_metrics.c
+++ b/src/vpp/api/vpp_get_metrics.c
@@ -95,7 +95,7 @@
}
if (sigaction (i, &sa, 0) < 0)
- return clib_unix_warning (0, "sigaction %U", format_signal, i);
+ return clib_unix_warning ("sigaction %U", format_signal, i);
}
}