From: Bruce Richardson Date: Wed, 1 May 2019 19:50:11 +0000 (+0100) Subject: net/ixgbe: fix warning with GCC 9 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=e81b0569cc6855fb4d95635d0ae8a749da5d0aed;p=dpdk.git net/ixgbe: fix warning with GCC 9 Compiling on Fedora 30, we get the following warning, causing build failure when Werror flag is set: ../drivers/net/ixgbe/ixgbe_rxtx.c:2141:14: warning: ‘nmb’ may be used uninitialized in this function [-Wmaybe-uninitialized] 2141 | rxe->mbuf = nmb; | ~~~~~~~~~~^~~~~ Initializing the value to "NULL" fixes the issue. Fixes: 8eecb3295aed ("ixgbe: add LRO support") Cc: stable@dpdk.org Signed-off-by: Bruce Richardson --- diff --git a/drivers/net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c index e71d3c188a..1fbc754aea 100644 --- a/drivers/net/ixgbe/ixgbe_rxtx.c +++ b/drivers/net/ixgbe/ixgbe_rxtx.c @@ -2029,7 +2029,7 @@ ixgbe_recv_pkts_lro(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts, struct ixgbe_rx_entry *next_rxe = NULL; struct rte_mbuf *first_seg; struct rte_mbuf *rxm; - struct rte_mbuf *nmb; + struct rte_mbuf *nmb = NULL; union ixgbe_adv_rx_desc rxd; uint16_t data_len; uint16_t next_id;