acl-plugin: fix coverity error that the fix related for [VPP-1502] has triggered 28/16128/3
authorAndrew Yourtchenko <ayourtch@gmail.com>
Fri, 23 Nov 2018 08:22:10 +0000 (09:22 +0100)
committerAndrew Yourtchenko <ayourtch@gmail.com>
Fri, 23 Nov 2018 11:45:56 +0000 (11:45 +0000)
commite0152461cbc84d6d4df3f05dddabe992c1c59052
tree35c267aedb48fc902aaeb741e459552d67547c1f
parent2a7b546fb05ecf5871350eca1f8fc6016c2d4ca8
acl-plugin: fix coverity error that the fix related for [VPP-1502] has triggered

Fix the trivial use-before-check copypaste error.

There was a more subtle issue with that patch that Coverity didn't notice:
namely, vec_validate(v, len-1) is a terrible idea if len happens to be == 0.
Fix that.

Change-Id: I0fab8b1750e9e9973eefb5d39f35e4c3a13fc66f
Signed-off-by: Andrew Yourtchenko <ayourtch@gmail.com>
src/plugins/acl/hash_lookup.c