linux/tools/iio
Alison Schofield ddbc719f99 tools: iio: iio_generic_buffer: initialize channel array pointer
Uninitialized channel pointer causes segmentation fault when we
call free(channel) during cleanup() with no channels initialized.
This happens when you exit early for usage errors.  Initialize
the pointer to NULL when it is declared.

Signed-off-by: Alison Schofield <amsfield22@gmail.com>
Cc: Daniel Baluta <daniel.baluta@gmail.com>
Tested-by: Gregor Boirie <gregor.boirie@parrot.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2016-08-15 17:05:30 +01:00
..
Makefile tools: iio: Rename generic_buffer to iio_generic_buffer 2016-05-29 19:56:33 +01:00
iio_event_monitor.c iio: Add channel for UV index 2016-04-03 11:14:01 +01:00
iio_generic_buffer.c tools: iio: iio_generic_buffer: initialize channel array pointer 2016-08-15 17:05:30 +01:00
iio_utils.c tools: iio: remove unnecessary double pointer 2015-08-08 19:54:00 +01:00
iio_utils.h iio: tools: generic_buffer: auto-enable channels 2016-04-19 19:58:13 +01:00
lsiio.c iio: lsiio: fix error code handling error 2015-08-12 19:26:22 +01:00