aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/interface_api.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/interface_api.c')
-rw-r--r--src/vnet/interface_api.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/vnet/interface_api.c b/src/vnet/interface_api.c
index 8b0cd8e4a33..4cd2ec95b0f 100644
--- a/src/vnet/interface_api.c
+++ b/src/vnet/interface_api.c
@@ -308,9 +308,9 @@ vl_api_sw_interface_dump_t_handler (vl_api_sw_interface_dump_t * mp)
u8 *filter = 0, *name = 0;
sw_if_index = ntohl (mp->sw_if_index);
- if (!mp->name_filter_valid && sw_if_index != ~0)
+ if (!mp->name_filter_valid && sw_if_index != ~0 && sw_if_index != 0)
{
- /* is it a valid sw_if_index/ */
+ /* is it a valid sw_if_index? */
if (vec_len (im->sw_interfaces) <= sw_if_index)
return;