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

Commit 96372774 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "libutils: Remove a little dead code" am: 4a39ba31 am: 0a8e5126

Original change: https://android-review.googlesource.com/c/platform/system/core/+/1977026

Change-Id: Ia93fbf37bde59db8da43bfffa0e75dad4ad0fd6b
parents 16149a30 0a8e5126
Loading
Loading
Loading
Loading
+1 −6
Original line number Diff line number Diff line
@@ -299,21 +299,16 @@ void androidSetCreateThreadFunc(android_create_thread_fn func)
int androidSetThreadPriority(pid_t tid, int pri)
{
    int rc = 0;
    int lasterr = 0;
    int curr_pri = getpriority(PRIO_PROCESS, tid);

    if (curr_pri == pri) {
        return rc;
    }

    if (rc) {
        lasterr = errno;
    }

    if (setpriority(PRIO_PROCESS, tid, pri) < 0) {
        rc = INVALID_OPERATION;
    } else {
        errno = lasterr;
        errno = 0;
    }

    return rc;