From 6e3c682b188cc0d1a80c165c4b2773574a163bb1 Mon Sep 17 00:00:00 2001 From: Dave Barach Date: Thu, 22 Mar 2018 08:15:05 -0400 Subject: VPP-1204: Fix coverity warning Change-Id: Iacb32e6e855f7b77108154d956ef27ee141bbde0 Signed-off-by: Dave Barach --- src/plugins/dpdk/device/init.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/plugins/dpdk/device') diff --git a/src/plugins/dpdk/device/init.c b/src/plugins/dpdk/device/init.c index a425c585dad..76d122d37d5 100755 --- a/src/plugins/dpdk/device/init.c +++ b/src/plugins/dpdk/device/init.c @@ -696,8 +696,11 @@ dpdk_lib_init (dpdk_main_t * dm) clib_warning ("VLAN strip cannot be supported by interface\n"); } - hi->max_l3_packet_bytes[VLIB_RX] = hi->max_l3_packet_bytes[VLIB_TX] = - xd->port_conf.rxmode.max_rx_pkt_len - sizeof (ethernet_header_t); + if (hi) + hi->max_l3_packet_bytes[VLIB_RX] = hi->max_l3_packet_bytes[VLIB_TX] = + xd->port_conf.rxmode.max_rx_pkt_len - sizeof (ethernet_header_t); + else + clib_warning ("hi NULL"); rte_eth_dev_set_mtu (xd->device_index, mtu); } -- cgit 1.2.3-korg