From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 37378A04AD; Mon, 24 Jan 2022 18:48:05 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B866342804; Mon, 24 Jan 2022 18:47:33 +0100 (CET) Received: from mail-pg1-f179.google.com (mail-pg1-f179.google.com [209.85.215.179]) by mails.dpdk.org (Postfix) with ESMTP id E985D427F1 for ; Mon, 24 Jan 2022 18:47:29 +0100 (CET) Received: by mail-pg1-f179.google.com with SMTP id f8so16019188pgf.8 for ; Mon, 24 Jan 2022 09:47:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=LthoC/aG80CawrgBqgZJqzxV3JgQQrhY5x+zkNuvJwE=; b=LlfDaXCtq+hjCq6l/WWZ4SLgqu4mlwZG3SdgEmKa/iNdo+HzwfZjaCzLwWwKaoKYMc WxADQcRrlR2Kl0p4jJRLz8ojQGweJrtB+hrORU+w6KPr98/+TKRMMkXYVZmWrAPR6zHy BNKQ52iWm72Y59WWjCwbGL01+lW8dMzi8zfcXUgz3oFxrWt1WtJCe4m6SEk63OzEjcKH RVj5+FyABx46T7acuySb/mrXXxnQQVlFVAXFFg1U+GVW+nItAJW85Xba+7kdZT2JpopR 9cDqPQEi+nuhQvprIbYAye9o3Wz1FdMzfsF9YxYbRi2t11gbkihwagupA99+sDcj8ZwG Q10A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=LthoC/aG80CawrgBqgZJqzxV3JgQQrhY5x+zkNuvJwE=; b=s2/nBSkPDZ6z54PHUTS/WSP8JJ5gJQoh9stfxcLxdmTaJe1v5x2rI+fAF2fnjhhvox 3cx/cFSa+Bu8bNAuqSYfQYklycMHUtD/k5FOyxXfHY3GLe2yKfvh36xgL7afD6SeSZJp sVLVLo3x4eqMlw6ZGTFegjs9T3wmafmpAX+aAjGGeBNduXXL8R55Gse0T9FDUrKU6vmR taPBCSkbpd/qooVLd4VIdK6OIdiCqV2AF56pYU58RYK43gBtY8q1JKRSwx+9AXrGH3XE zkZ7gTKwWjk9kCSFwjtgOs/TxT7wkieUtiHisVqNW495KG7VZ5tRXJOgWBmH39R8vLA2 iHcw== X-Gm-Message-State: AOAM530fPNmOZJLIiVj1VJlL0tlIzGNcKRuT2fMuKr2MFqYTW43GSLIi HtryN4aykTgZ1rd+geACG8dbRUtK1RuqJw== X-Google-Smtp-Source: ABdhPJwWqu4J55phZaHl3hdSvEVNnzyZhn7e8FVO3/S2q7jpVsvZbeIwFEzrqroO7ZMCW/01jn2fZA== X-Received: by 2002:a05:6a00:15d1:b0:4c1:e1d2:347c with SMTP id o17-20020a056a0015d100b004c1e1d2347cmr14981453pfu.29.1643046448971; Mon, 24 Jan 2022 09:47:28 -0800 (PST) Received: from hermes.local (204-195-112-199.wavecable.com. [204.195.112.199]) by smtp.gmail.com with ESMTPSA id q7sm15835082pfs.37.2022.01.24.09.47.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Jan 2022 09:47:28 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Cristian Dumitrescu Subject: [PATCH v2 07/83] examples/pipeline/thread: remove unnecessary NULL checks Date: Mon, 24 Jan 2022 09:46:03 -0800 Message-Id: <20220124174719.14417-8-stephen@networkplumber.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220124174719.14417-1-stephen@networkplumber.org> References: <20220124000518.319850-1-stephen@networkplumber.org> <20220124174719.14417-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Remove redundant NULL pointer checks before free functions found by nullfree.cocci Signed-off-by: Stephen Hemminger --- examples/pipeline/thread.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/examples/pipeline/thread.c b/examples/pipeline/thread.c index bf11e6144b75..5fe7eae00eb6 100644 --- a/examples/pipeline/thread.c +++ b/examples/pipeline/thread.c @@ -89,11 +89,9 @@ thread_free(void) continue; /* MSGQs */ - if (t->msgq_req) - rte_ring_free(t->msgq_req); + rte_ring_free(t->msgq_req); - if (t->msgq_rsp) - rte_ring_free(t->msgq_rsp); + rte_ring_free(t->msgq_rsp); } } -- 2.30.2