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

Commit bce60b2c authored by Ethan Chen's avatar Ethan Chen Committed by Adnan Begovic
Browse files

MountService: Check for null pointer when looking for vold code

* There is actually no code path that will set an event into
  NativeDaemonConnectorException, so any reference to the event code
  will result in a null pointer exception, taking down MountService and
  the rest of the system with it.

Change-Id: Id62f724953aacc363b3455584c6a3ad1381c6138
(cherry picked from commit 31f051ab)
parent 54af32d2
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -41,7 +41,12 @@ public class NativeDaemonConnectorException extends Exception {
    }

    public int getCode() {
        if (mEvent != null) {
            return mEvent.getCode();
        } else {
            /* Will be caught by default case */
            return -1;
        }
    }

    public String getCmd() {