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

Commit bee229f7 authored by Liz Prucka's avatar Liz Prucka
Browse files

[Intrusion Logging] Bugfix: Add null check in test app

Flake in the SeucrityEventLogging tests is caused by
a missing null check in IntrusionLogging tests.

Bug: 423944078
Test: atest android.security.cts.IntrusionDetectionManagerTest
Ignore-AOSP-First: security feature
Flag: EXEMPT: bugfix for tests in localized component
Change-Id: I4073fe1d9eb1d4ec7b7af662d88900a35156de16
parent f2c07b66
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -83,6 +83,9 @@ public class LocalIntrusionDetectionEventTransport extends IntrusionDetectionEve
        for (IntrusionDetectionEvent event : events) {
            if (event.getType() == IntrusionDetectionEvent.SECURITY_EVENT) {
                SecurityEvent securityEvent = event.getSecurityEvent();
                if (securityEvent.getData() == null) {
                    continue;
                }
                Object[] eventData = (Object[]) securityEvent.getData();
                if (securityEvent.getTag() == SecurityLog.TAG_KEY_GENERATED
                        && eventData[1].equals(TEST_SECURITY_EVENT_TAG)) {