Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit de73a0cf authored by OPPO's avatar OPPO Committed by Jimin Wang
Browse files

Sync persist property immediately,in case of suddenly remove the battery.

Change-Id: I83c5812c69db532f4675f5dbfa508e55999c8dfe
parent 47770b73
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -269,6 +269,7 @@ static void write_persistent_property(const char *name, const char *value)
        return;
    }
    write(fd, value, strlen(value));
    fsync(fd);
    close(fd);

    snprintf(path, sizeof(path), "%s/%s", PERSISTENT_PROPERTY_DIR, name);