patch 'app/testpmd: verify strdup return' has been queued to stable release 23.11.1

Xueming Li xuemingl at nvidia.com
Tue Mar 5 10:46:19 CET 2024


Hi,

FYI, your patch has been queued to stable release 23.11.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 03/31/24. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://git.dpdk.org/dpdk-stable/log/?h=23.11-staging

This queued commit can be viewed at:
https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c830d9e2afb0cdb8748d8d31347a36f24ea039c6

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From c830d9e2afb0cdb8748d8d31347a36f24ea039c6 Mon Sep 17 00:00:00 2001
From: Chengwen Feng <fengchengwen at huawei.com>
Date: Fri, 10 Nov 2023 10:01:15 +0000
Subject: [PATCH] app/testpmd: verify strdup return
Cc: Xueming Li <xuemingl at nvidia.com>

[ upstream commit 365cdd7d01f70da2b10671aea05c5aaa036d3771 ]

Add verify strdup return value logic.

Fixes: 52e2e7edcf48 ("app/testpmd: add protocol-based buffer split")

Signed-off-by: Chengwen Feng <fengchengwen at huawei.com>
Acked-by: Ivan Malov <ivan.malov at arknetworks.am>
Acked-by: Huisong Li <lihuisong at huawei.com>
---
 app/test-pmd/cmdline.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index 9369d3b4c5..d9304e4a32 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -3528,6 +3528,8 @@ parse_hdrs_list(const char *str, const char *item_name, unsigned int max_items,

 	nb_item = 0;
 	char *str2 = strdup(str);
+	if (str2 == NULL)
+		return nb_item;
 	cur = strtok_r(str2, ",", &tmp);
 	while (cur != NULL) {
 		parsed_items[nb_item] = get_ptype(cur);
--
2.34.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2024-03-05 17:39:32.189705840 +0800
+++ 0038-app-testpmd-verify-strdup-return.patch	2024-03-05 17:39:30.733566492 +0800
@@ -1 +1 @@
-From 365cdd7d01f70da2b10671aea05c5aaa036d3771 Mon Sep 17 00:00:00 2001
+From c830d9e2afb0cdb8748d8d31347a36f24ea039c6 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 365cdd7d01f70da2b10671aea05c5aaa036d3771 ]
@@ -9 +11,0 @@
-Cc: stable at dpdk.org


More information about the stable mailing list