staging:iio:core simplify and fix a bug in iio_device_(un)register_event_set.
authorJonathan Cameron <jic23@cam.ac.uk>
Fri, 12 Aug 2011 15:55:30 +0000 (16:55 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 23 Aug 2011 20:28:42 +0000 (13:28 -0700)
commitcc2439fdecb85f27866cab0ae1cbf21a9b61c423
treeaa657228a17bbc86520bdc94b08a5b9dd468b14b
parentcd0380190f7c7ad8d5a8f15403a67fedd37fcddb
staging:iio:core simplify and fix a bug in iio_device_(un)register_event_set.

The unwinding index was j, not i and it is much simpler to do these as a single
loop unwinding those elements necessary in before jumping to the error handler.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/iio/industrialio-core.c