Always trigger safe mode callbacks
This change ensures that safe mode callbacks are always triggered from
the VcnGatewayConnection up, ensuring that if a gateway connection
is restarted and successfully validates, it will notify the Vcn class,
and kick it out of safe mode.
Previously, if a VCN had entered safe mode, and a config was updated,
the newly updated VcnGatewayConnection would be brought up as "not" in
safe mode, and thus the onSafeModeStatusChanged() callback would never
be fired if the new VcnGatewayConnection successfully connected.
Calling onSafeModeStatusChanged() multiple times is safe, and serves as
a "connection status changed" callback.
Bug: 196841140
Test: atest FrameworksVcnTests
Test: manual testing
Original-Change: https://android-review.googlesource.com/1811936
Change-Id: I43c82ada9e9429e8283be65ab73d13075dfd6038
Merged-In: I856517924d0a767b63ea6127b7d4e39e09e93f2c
(cherry picked from commit 7cf35e7bd940c6f4ee0035a4c1b081c71c85c7f9)
4 files changed