Ensure that android is restarted when setting sysprop flag.

Bug: 219067621
Test: manual
Change-Id: I81cf7d0b7ae99a38b202156ce61eb94584d0d749
This commit is contained in:
Dave Mankoff
2022-02-24 17:08:45 -05:00
parent d0cb324a9c
commit 115a3ed705

View File

@@ -317,6 +317,8 @@ public class FeatureFlagsDebug implements FeatureFlags, Dumpable {
// Store SysProp flags in SystemProperties where they can read by outside parties.
mSystemProperties.setBoolean(
((SysPropBooleanFlag) flag).getName(), (Boolean) value);
dispatchListenersAndMaybeRestart(flag.getId(),
FeatureFlagsDebug.this::restartAndroid);
} else if (flag instanceof StringFlag && value instanceof String) {
setFlagValue(id, (String) value, StringFlagSerializer.INSTANCE);
} else if (flag instanceof ResourceStringFlag && value instanceof String) {