FlagManager: Move mInstance to getMutableInstance
The static globals mOnce and mInstance in FlagManager could potentially
cause initialization issues between objects when referencing each other.
We solve this by:
1. Move mInstance to getMutableInstance() in FlagManager, and
2. Get rid of mOnce in favor of the static initialization of mInstance
from within getMutableInstance().
We also remove ConstructorTag{} in favor of a default private
constructor, since a specialized ctor for std::make_unique is no longer
necessary.
Flag: EXEMPT refactor
Bug: 421221131
Test: libsurfaceflinger_unittest
Change-Id: I22e838a8e25a266f155527121e68f89571ba03fb
Loading
Please register or sign in to comment