aboutsummaryrefslogtreecommitdiff
path: root/src/systemcmds/tests/test_adc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/systemcmds/tests/test_adc.c')
-rw-r--r--src/systemcmds/tests/test_adc.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/systemcmds/tests/test_adc.c b/src/systemcmds/tests/test_adc.c
index 9f6905239..ef12c9ad2 100644
--- a/src/systemcmds/tests/test_adc.c
+++ b/src/systemcmds/tests/test_adc.c
@@ -71,8 +71,9 @@ int test_adc(int argc, char *argv[])
/* read all channels available */
ssize_t count = read(fd, data, sizeof(data));
- if (count < 0)
+ if (count < 0) {
goto errout_with_dev;
+ }
unsigned channels = count / sizeof(data[0]);
@@ -88,7 +89,7 @@ int test_adc(int argc, char *argv[])
errout_with_dev:
- if (fd != 0) close(fd);
+ if (fd != 0) { close(fd); }
return OK;
}