linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: linux-iio@vger.kernel.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	devel@driverdev.osuosl.org
Subject: Re: [PATCH] staging: iio: generic_buffer: initialize ret
Date: Sat, 12 Oct 2013 12:20:09 +0100	[thread overview]
Message-ID: <52593069.2080908@kernel.org> (raw)
In-Reply-To: <1381149748-9341-1-git-send-email-bigeasy@linutronix.de>

On 10/07/13 13:42, Sebastian Andrzej Siewior wrote:
> The `ret´ variable is only initialized in the error case. For some reason
> it was always != 0 while I played with generic_buffer so here is a patch.
> 
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Thanks,

Applied to the togreg branch of iio.git

> ---
>  drivers/staging/iio/Documentation/iio_utils.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/iio/Documentation/iio_utils.h b/drivers/staging/iio/Documentation/iio_utils.h
> index cf32ae0..35154d6 100644
> --- a/drivers/staging/iio/Documentation/iio_utils.h
> +++ b/drivers/staging/iio/Documentation/iio_utils.h
> @@ -502,7 +502,7 @@ inline int find_type_by_name(const char *name, const char *type)
>  
>  inline int _write_sysfs_int(char *filename, char *basedir, int val, int verify)
>  {
> -	int ret;
> +	int ret = 0;
>  	FILE *sysfsfp;
>  	int test;
>  	char *temp = malloc(strlen(basedir) + strlen(filename) + 2);
> 

      reply	other threads:[~2013-10-12 10:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-07 12:42 [PATCH] staging: iio: generic_buffer: initialize ret Sebastian Andrzej Siewior
2013-10-12 11:20 ` Jonathan Cameron [this message]

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=52593069.2080908@kernel.org \
    --to=jic23@kernel.org \
    --cc=bigeasy@linutronix.de \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-iio@vger.kernel.org \
    /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).