From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 93A24A046B for ; Thu, 22 Aug 2019 10:31:06 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 608E81BF5A; Thu, 22 Aug 2019 10:31:06 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by dpdk.org (Postfix) with ESMTP id 3F17B1BF57 for ; Thu, 22 Aug 2019 10:31:05 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x7M8TiAV001231; Thu, 22 Aug 2019 01:31:04 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding : content-type; s=pfpt0818; bh=8C+6oESVWtMa+h9596IOAZsXqO9wR5c1poiAnvNyXVo=; b=FnsK5PAx3nurXYK62d8baNkRYPp55kHTNDFBwjR655R8vgHGG1RoG1XHfn+p5/GXTlPM mqlZUxaKV6Xk8heTgvwn5a+hvu4uW07WW+0GALIhe9+T0dztqMf8UkAl2WbTUFIM2TFy vgY1ObKANYeEpwvPVO2Ayxp1+oO3agqBJDKT5qZiHti3XpWpwfL5L5h7rR3ntDRyo0iC WkZCE41IVr+ldjrXNtGM7yizt7h+aGuZhEVxIdlnh2YAUMky98PlZU+uUM1juVNQOheJ XiEM27YY9Da17YxTspNJxdh96v5ZRgiYCr8/EcKD1+iXP8la871XmrnZV7ehjyjRqRru Dw== Received: from sc-exch02.marvell.com ([199.233.58.182]) by mx0b-0016f401.pphosted.com with ESMTP id 2uhag22rx8-2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Thu, 22 Aug 2019 01:31:04 -0700 Received: from SC-EXCH01.marvell.com (10.93.176.81) by SC-EXCH02.marvell.com (10.93.176.82) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Thu, 22 Aug 2019 01:31:03 -0700 Received: from maili.marvell.com (10.93.176.43) by SC-EXCH01.marvell.com (10.93.176.81) with Microsoft SMTP Server id 15.0.1367.3 via Frontend Transport; Thu, 22 Aug 2019 01:31:03 -0700 Received: from ajoseph83.caveonetworks.com.com (unknown [10.29.45.56]) by maili.marvell.com (Postfix) with ESMTP id 75D653F703F; Thu, 22 Aug 2019 01:31:00 -0700 (PDT) From: Anoob Joseph To: Akhil Goyal , Pablo de Lara , Radu Nicolau CC: Anoob Joseph , Jerin Jacob , Lukasz Bartosik , Narayana Prasad , Date: Thu, 22 Aug 2019 13:58:55 +0530 Message-ID: <1566462535-17425-1-git-send-email-anoobj@marvell.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:5.22.84,1.0.8 definitions=2019-08-22_05:2019-08-19,2019-08-22 signatures=0 Subject: [dpdk-dev] [PATCH] examples/ipsec-secgw: fix access to freed packet X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" For unknown/unsupported packets, the packet would get checked for inline offloads after the packet is freed. Fixes: 0ccfd14bc10d ("examples/ipsec-secgw: support inline protocol") Signed-off-by: Anoob Joseph --- examples/ipsec-secgw/ipsec-secgw.c | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c index 0d1fd6a..fcd656b 100644 --- a/examples/ipsec-secgw/ipsec-secgw.c +++ b/examples/ipsec-secgw/ipsec-secgw.c @@ -353,6 +353,7 @@ prepare_one_packet(struct rte_mbuf *pkt, struct ipsec_traffic *t) RTE_LOG(ERR, IPSEC, "Unsupported packet type 0x%x\n", rte_be_to_cpu_16(eth->ether_type)); rte_pktmbuf_free(pkt); + return; } /* Check if the packet has been processed inline. For inline protocol -- 2.7.4