Hash :
a6699c9f
Author :
Date :
2025-07-23T13:33:48
Android: Stop polling messages when app destroy requested The Chromium Android testing app enters an infinite loop to poll for messages to run the tests. However, this prevents the app from gracefully shutting down when the DESTROY event is received, because android_main() never returns, so the NDK function android_app_free() never sees android_app->destroyed become true. This prevents using Android instrumented tests in CTS, because the instrumentation never sees the ANGLE app complete the handling of the DESTROY event and exit cleanly. To fix this, check sApp->destroyRequested after each event and break from the infinite loop if the app is being destroyed. Bug: b/279980674 Change-Id: I63edaa6d64e57cd99b6b63a9631c30a65c416220 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6781760 Reviewed-by: Yuxin Hu <yuxinhu@google.com> Commit-Queue: Tim Van Patten <timvp@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com>