Fix a complaint by SVACE static analysis 55/214055/2
authorMichal Bloch <m.bloch@partner.samsung.com>
Tue, 17 Sep 2019 10:39:08 +0000 (12:39 +0200)
committerMichal Bloch <m.bloch@partner.samsung.com>
Tue, 17 Sep 2019 13:56:40 +0000 (13:56 +0000)
Change-Id: I289f2d9684332ee1bf7e9b8eb3f971e177443ef3
Signed-off-by: Michal Bloch <m.bloch@partner.samsung.com>
tests/watchdog-test.c

index b654e1a..7deff90 100644 (file)
@@ -109,7 +109,9 @@ void save_core_pattern()
        if (fd < 0)
                return;
        ret = read(fd, core_pattern, sizeof(core_pattern));
-       if (ret < 0);                           /* do nothing */
+       if (ret < 0) {
+               // do nothing
+       }
        close(fd);
 }
 
@@ -121,7 +123,9 @@ void set_core_pattern(const char *t)
        if (fd < 0)
                return;
        ret = write(fd, t, strlen(t));
-       if (ret < 0);                           /* do nothing */
+       if (ret < 0) {
+               // do nothing
+       }
        close(fd);
 }