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

Commit 7b732669 authored by Tetsutoki Shiozawa's avatar Tetsutoki Shiozawa Committed by Shunta Sato
Browse files

Init MemoryIntArray#mFd with -1

Symptom:
mFd was left uninitialized when constructor was failed.
As a result, it tried to close mFd=0 at finalize and
it crashed with SIGABRT.

Bug: 35791084

Change-Id: I913975ce3e8524a4e323f948621509e4655de17b
parent 35c89886
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -54,7 +54,7 @@ public final class MemoryIntArray implements Parcelable, Closeable {
    private final int mOwnerPid;
    private final boolean mClientWritable;
    private final long mMemoryAddr;
    private int mFd;
    private int mFd = -1;

    /**
     * Creates a new instance.