Fix handling multiple staged rollback sessions ready signal
After we stage a session for rollback, we need to wait for the session to be ready and then reboot. To ensure we don't miss the ready signal, we register a BroadcastReceiver to listen to session changes and also check for session ready right away. This caused a race condition where we may handle post-ready twice. This caused a crash because we attempt to unregister the receiver twice, it's also a problem because we could log the same event twice. Now, we store the rollback ids we are about to handle and ensure we never handle post-ready more than once. Test: Manual test && atest StagedRollbackTest Bug: 132866890 Change-Id: I5187ff20fb83b29f7a00a28bf6ad8105ca4f0067
Loading
Please register or sign in to comment