diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2013-10-07 12:42:00 (GMT) |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2013-10-12 11:19:50 (GMT) |
commit | 11cb454f092397b8cb1ba478efaa5743bea604a2 (patch) | |
tree | 94f50b4de9011d7390d16cd9ce2412eddb3db7d4 | |
parent | 84088ebd14aebf1b8499409a037094b9b88e2796 (diff) | |
download | linux-fsl-qoriq-11cb454f092397b8cb1ba478efaa5743bea604a2.tar.xz |
staging: iio: generic_buffer: initialize ret
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>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
-rw-r--r-- | drivers/staging/iio/Documentation/iio_utils.h | 2 |
1 files changed, 1 insertions, 1 deletions
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); |