summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2019-03-30 10:24:28 -0400
committerDave Barach <openvpp@barachs.net>2019-03-30 18:14:44 +0000
commitac3b1139578b544cae3884548f455a1e7b4910f4 (patch)
tree02945e6a1f1e5e0d738474b026b8d088b4601d80
parent65ec33bd006406c220cb6acb93fdd97894b0107c (diff)
VPP-1576: fix a class of spurious warnings
Change-Id: I52198e97397bb6f3b5c0c30c44aac34c17650d4d Signed-off-by: Dave Barach <dave@barachs.net>
-rw-r--r--src/vppinfra/format.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/vppinfra/format.c b/src/vppinfra/format.c
index 072ff3b3362..cb6cb455eaa 100644
--- a/src/vppinfra/format.c
+++ b/src/vppinfra/format.c
@@ -412,6 +412,11 @@ va_format (u8 * s, const char *fmt, va_list * va)
if (f > g)
vec_add (s, g, f - g);
+#ifdef __COVERITY__
+ if (s == 0)
+ return (u8 *) "liar liar pants on fire s can't be zero!";
+#endif
+
return s;
}