DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Dumitrescu, Cristian" <cristian.dumitrescu@intel.com>
To: Thomas Monjalon <thomas.monjalon@6wind.com>,
	"dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] examples/ip_pipeline: fix build with clang 3.6
Date: Tue, 19 May 2015 15:32:29 +0000	[thread overview]
Message-ID: <3EB4FA525960D640B5BDFFD6A3D8912632369F33@IRSMSX108.ger.corp.intel.com> (raw)
In-Reply-To: <1432031834-12042-1-git-send-email-thomas.monjalon@6wind.com>



> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Thomas Monjalon
> Sent: Tuesday, May 19, 2015 11:37 AM
> To: dev@dpdk.org
> Subject: [dpdk-dev] [PATCH] examples/ip_pipeline: fix build with clang 3.6
> 
> 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 <thomas.monjalon@6wind.com>
> ---
>  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

Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>

  reply	other threads:[~2015-05-19 15:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-19 10:37 Thomas Monjalon
2015-05-19 15:32 ` Dumitrescu, Cristian [this message]
2015-05-19 15:46   ` Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3EB4FA525960D640B5BDFFD6A3D8912632369F33@IRSMSX108.ger.corp.intel.com \
    --to=cristian.dumitrescu@intel.com \
    --cc=dev@dpdk.org \
    --cc=thomas.monjalon@6wind.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).