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

Commit 75a63a4e authored by Bart Van Assche's avatar Bart Van Assche Committed by Automerger Merge Worker
Browse files

Merge "Fix the stat() return value check in createProcessGroupInternal()" am: a6c82269

parents 04b1e6e6 a6c82269
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -464,7 +464,7 @@ static int createProcessGroupInternal(uid_t uid, int initialPid, std::string cgr
    gid_t cgroup_gid = AID_SYSTEM;
    gid_t cgroup_gid = AID_SYSTEM;
    int ret = 0;
    int ret = 0;


    if (stat(cgroup.c_str(), &cgroup_stat) == 1) {
    if (stat(cgroup.c_str(), &cgroup_stat) < 0) {
        PLOG(ERROR) << "Failed to get stats for " << cgroup;
        PLOG(ERROR) << "Failed to get stats for " << cgroup;
    } else {
    } else {
        cgroup_mode = cgroup_stat.st_mode;
        cgroup_mode = cgroup_stat.st_mode;