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 C7479A04E6 for ; Tue, 17 Nov 2020 18:15:07 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id A7640C8B4; Tue, 17 Nov 2020 18:15:04 +0100 (CET) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id B52635928; Tue, 17 Nov 2020 18:14:59 +0100 (CET) IronPort-SDR: emejCN7XBT7UmPbw5i4Isi+q87v961idBRF9YcOGE+h9Hy2FZq+ukD9I6//rDEWATQ/b81MGVv eIMLvwW3xhMA== X-IronPort-AV: E=McAfee;i="6000,8403,9808"; a="157997949" X-IronPort-AV: E=Sophos;i="5.77,486,1596524400"; d="scan'208";a="157997949" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Nov 2020 09:14:54 -0800 IronPort-SDR: QNfSFkF9ddf2VTl3JfGVI8r1z08yhMqmO7YpyZyAV3FaLHc4XdZPOxP13uOwfDlTjGiSLLHU4v XxjvR8Sl4GPg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.77,486,1596524400"; d="scan'208";a="330146823" Received: from silpixa00399752.ir.intel.com (HELO silpixa00399752.ger.corp.intel.com) ([10.237.222.180]) by orsmga006.jf.intel.com with ESMTP; 17 Nov 2020 09:14:51 -0800 From: Ferruh Yigit To: Maryam Tahhan , Reshma Pattan , Harry van Haaren , Roman Korynkevych Cc: Ferruh Yigit , dev@dpdk.org, stable@dpdk.org Date: Tue, 17 Nov 2020 17:14:32 +0000 Message-Id: <20201117171435.2303641-2-ferruh.yigit@intel.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201117171435.2303641-1-ferruh.yigit@intel.com> References: <20201117171435.2303641-1-ferruh.yigit@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] [PATCH 1/4] app/procinfo: fix redundant condition X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" '_filters' is compared twice, second one will be always false, removing it using the message more relevant to the '_filters'. Fixes: 2deb6b5246d7 ("app/procinfo: add collectd format and host id") Cc: stable@dpdk.org Signed-off-by: Ferruh Yigit --- Cc: romanx.korynkevych@intel.com --- app/proc-info/main.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/proc-info/main.c b/app/proc-info/main.c index d743209f0d..35e5b596eb 100644 --- a/app/proc-info/main.c +++ b/app/proc-info/main.c @@ -420,11 +420,9 @@ static void collectd_resolve_cnt_type(char *cnt_type, size_t cnt_type_len, } else if ((type_end != NULL) && (strncmp(cnt_name, "flow_", strlen("flow_"))) == 0) { if (strncmp(type_end, "_filters", strlen("_filters")) == 0) - strlcpy(cnt_type, "operations", cnt_type_len); + strlcpy(cnt_type, "filter_result", cnt_type_len); else if (strncmp(type_end, "_errors", strlen("_errors")) == 0) strlcpy(cnt_type, "errors", cnt_type_len); - else if (strncmp(type_end, "_filters", strlen("_filters")) == 0) - strlcpy(cnt_type, "filter_result", cnt_type_len); } else if ((type_end != NULL) && (strncmp(cnt_name, "mac_", strlen("mac_"))) == 0) { if (strncmp(type_end, "_errors", strlen("_errors")) == 0) -- 2.26.2