From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: [PATCH] examples/ip_pipeline: fix build with clang 3.6 Date: Tue, 19 May 2015 12:37:14 +0200 Message-ID: <1432031834-12042-1-git-send-email-thomas.monjalon@6wind.com> To: dev@dpdk.org Return-path: Received: from mail-wi0-f177.google.com (mail-wi0-f177.google.com [209.85.212.177]) by dpdk.org (Postfix) with ESMTP id AFDFEC320 for ; Tue, 19 May 2015 12:38:01 +0200 (CEST) Received: by wizk4 with SMTP id k4so111858108wiz.1 for ; Tue, 19 May 2015 03:38:01 -0700 (PDT) Received: from XPS13.nsn-net.net ([62.159.77.186]) by mx.google.com with ESMTPSA id ex2sm21148490wjd.28.2015.05.19.03.38.00 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 19 May 2015 03:38:00 -0700 (PDT) List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" This error is detected: examples/ip_pipeline/cmdline.c:272:15: error: address of array 'params->file_path' will always evaluate to 'true' if (!params->file_path) { ~~~~~~~~~^~~~~~~~~ file_path is an array in a structure so it's unneeded to check it. Signed-off-by: Thomas Monjalon --- examples/ip_pipeline/cmdline.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/examples/ip_pipeline/cmdline.c b/examples/ip_pipeline/cmdline.c index 152acb5..3173fd0 100644 --- a/examples/ip_pipeline/cmdline.c +++ b/examples/ip_pipeline/cmdline.c @@ -268,12 +268,6 @@ cmd_run_file_parsed( struct cmdline *file_cl; int fd; - /* Check params */ - if (!params->file_path) { - printf("Illegal value for file path (%s)\n", params->file_path); - return; - } - fd = open(params->file_path, O_RDONLY, 0); if (fd < 0) { printf("Illegal value for file path (%s)\n", params->file_path); -- 2.4.0