tools: iio: iio_generic_buffer: drop unneeded parentheses
authorEva Rachel Retuya <eraretuya@gmail.com>
Thu, 20 Oct 2016 09:19:24 +0000 (17:19 +0800)
committerJonathan Cameron <jic23@kernel.org>
Sun, 23 Oct 2016 18:34:10 +0000 (19:34 +0100)
Remove extra parentheses introduced in commit <73e176a tools: iio:
iio_generic_buffer: add -A to force-enable all channels>.

Suggested-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net>
Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
tools/iio/iio_generic_buffer.c

index 8ef39ae9858f7f66ac781b4573133a687194c3bf..f0c6f54a8b2ff2199e70f1d08569110da004768d 100644 (file)
@@ -526,7 +526,7 @@ int main(int argc, char **argv)
                        "diag %s\n", dev_dir_name);
                goto error;
        }
-       if ((num_channels && autochannels == AUTOCHANNELS_ENABLED) &&
+       if (num_channels && autochannels == AUTOCHANNELS_ENABLED &&
            !force_autochannels) {
                fprintf(stderr, "Auto-channels selected but some channels "
                        "are already activated in sysfs\n");
@@ -534,7 +534,7 @@ int main(int argc, char **argv)
        }
 
        if ((!num_channels && autochannels == AUTOCHANNELS_ENABLED) ||
-           ((autochannels == AUTOCHANNELS_ENABLED) && force_autochannels)) {
+           (autochannels == AUTOCHANNELS_ENABLED && force_autochannels)) {
                fprintf(stderr, "Enabling all channels\n");
 
                ret = enable_disable_all_channels(dev_dir_name, 1);