vhost: debug vhost-user command needs better error checking on the syntax (VPP-916) 12/7712/1
authorSteven <sluong@cisco.com>
Fri, 21 Jul 2017 23:38:41 +0000 (16:38 -0700)
committerSteven <sluong@cisco.com>
Fri, 21 Jul 2017 23:38:41 +0000 (16:38 -0700)
commit6a4de2764d9e6cadf36af824dddb3f33c2d6dc7e
tree140af2bbab0b44a6b045972dd411e9b0e1f9df92
parent45fe7399152f5ca511ba0b03fee3d5a3dffd1897
vhost: debug vhost-user command needs better error checking on the syntax (VPP-916)

The syntax for debug vhost-user is
debug vhost-user <on | off>

However, currently the code does not reject the invalid command such as below
debug vhost-user
debug vhost-user on blah
debug vhost-user off blah

The fix is to enforece the correct syntax and reject the command when invalid
option is entered.

Change-Id: I1a04ae8ddb6dd299aa6d15b043362964e685ddde
Signed-off-by: Steven <sluong@cisco.com>
src/vnet/devices/virtio/vhost-user.c