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

Commit 87ad1fce authored by Chris Tate's avatar Chris Tate Committed by Android (Google) Code Review
Browse files

Merge "Build JobStatus objects outside the lock" into nyc-dev

parents 8b655e0f 3eddecc3
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -223,10 +223,11 @@ public class JobServiceContext extends IJobCallback.Stub implements ServiceConne
     * stop executing.
     */
    JobStatus getRunningJob() {
        final JobStatus job;
        synchronized (mLock) {
            return mRunningJob == null ?
                    null : new JobStatus(mRunningJob);
            job = mRunningJob;
        }
        return job == null ? null : new JobStatus(job);
    }

    /** Called externally when a job that was scheduled for execution should be cancelled. */