Create temporary file to check wifi firmware state #3 92/191692/1 submit/tizen/20181022.095216
authorSeonah Moon <seonah1.moon@samsung.com>
Mon, 22 Oct 2018 09:31:20 +0000 (18:31 +0900)
committerSeonah Moon <seonah1.moon@samsung.com>
Mon, 22 Oct 2018 09:31:24 +0000 (18:31 +0900)
Change-Id: I174f255dc49f2883b5ddc945e4375720327dc820

src/wifi.c

index 0bc5273..8d3303a 100755 (executable)
@@ -120,7 +120,7 @@ static void _update_wifi_firmware_state(void)
        mode_t mode = S_IRGRP | S_IWUSR | S_IXGRP;
 
        fd = creat(SPRD_CP2_FIRMWARE_STATE_PATH, mode);
-       if (fd > 0)
+       if (fd >= 0)
                close(fd);
        else
                DBG("Failed to create wifi firmware state file");