From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id DE1DF231C for ; Mon, 7 Nov 2016 02:25:20 +0100 (CET) Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga104.jf.intel.com with ESMTP; 06 Nov 2016 17:25:19 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,604,1473145200"; d="scan'208";a="28192511" Received: from dpdk26.sh.intel.com ([10.239.128.228]) by fmsmga005.fm.intel.com with ESMTP; 06 Nov 2016 17:25:18 -0800 From: Wenzhuo Lu To: dev@dpdk.org Cc: adrien.mazarguil@6wind.com, konstantin.ananyev@intel.com, Wenzhuo Lu Date: Sun, 6 Nov 2016 12:16:14 -0500 Message-Id: <1478452574-127074-1-git-send-email-wenzhuo.lu@intel.com> X-Mailer: git-send-email 1.9.3 Subject: [dpdk-dev] [PATCH] lib/ip_frag: fix IP reassembly not working issue X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Nov 2016 01:25:21 -0000 After changing pkt[0] to pkt[], the example IP reassembly is not working. It's weird because this change is fine. There should be no difference between them. As a workaround, revert this change. Fixes: 347a1e037fd3 (lib: use C99 syntax for zero-size arrays) Reported-by: Huilong Xu Signed-off-by: Wenzhuo Lu --- lib/librte_ip_frag/rte_ip_frag.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_ip_frag/rte_ip_frag.h b/lib/librte_ip_frag/rte_ip_frag.h index 69596ab..6708906 100644 --- a/lib/librte_ip_frag/rte_ip_frag.h +++ b/lib/librte_ip_frag/rte_ip_frag.h @@ -124,7 +124,7 @@ struct rte_ip_frag_tbl { struct ip_frag_pkt *last; /**< last used entry. */ struct ip_pkt_list lru; /**< LRU list for table entries. */ struct ip_frag_tbl_stat stat; /**< statistics counters. */ - struct ip_frag_pkt pkt[]; /**< hash table. */ + __extension__ struct ip_frag_pkt pkt[0]; /**< hash table. */ }; /** IPv6 fragment extension header */ -- 1.9.3