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

Commit 0430207a authored by Felipe Leme's avatar Felipe Leme
Browse files

Don't WTF when assist structure is missing.

That could happen when app throws an exception while filling it.

Fixes: 38312929
Test: manual verification by forcing an app to throw an exception

Change-Id: I7e94e9d352c4c3fd8adf01bcf7b25f66535e070d
parent 06fe8229
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -174,13 +174,13 @@ final class Session implements RemoteFillService.FillServiceCallbacks, ViewState
        public void send(int resultCode, Bundle resultData) throws RemoteException {
            final AssistStructure structure = resultData.getParcelable(KEY_STRUCTURE);
            if (structure == null) {
                Slog.wtf(TAG, "no assist structure");
                Slog.e(TAG, "No assist structure - app might have crashed providing it");
                return;
            }

            final Bundle receiverExtras = resultData.getBundle(KEY_RECEIVER_EXTRAS);
            if (receiverExtras == null) {
                Slog.wtf(TAG, "No " + KEY_RECEIVER_EXTRAS + " on receiver");
                Slog.e(TAG, "No receiver extras - app might have crashed providing it");
                return;
            }