stats: fix coverity issues 71/30271/2
authorAndrew Yourtchenko <ayourtch@gmail.com>
Fri, 4 Dec 2020 07:22:01 +0000 (07:22 +0000)
committerOle Tr�an <otroan@employees.org>
Fri, 4 Dec 2020 08:41:38 +0000 (08:41 +0000)
commit86ffb6b232d5ebce03cf53249fa1514384f31cce
tree69081f9176200f415753d3da3870f48a28266078
parent068ad25c1ac1215761e1436abfc2033a6bb71b64
stats: fix coverity issues

Usage of the possibly negative value with subsequent check on it
makes coverity very unhappy, so put the check before use.

Change-Id: I731fbe6246f9e4212d546fd9277bc1ddcd3c2ec1
Type: fix
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
src/vpp/stats/stat_segment.c