init: Do not invoke the ServiceList destructor when exiting
From the Google C++ style guide: "Objects with static storage duration are forbidden unless they are trivially destructible." Hence this CL. Bug: 213617178 Change-Id: I4c9a51618ee1eb14ed439295a5fc0101b940a63d Signed-off-by: Bart Van Assche <bvanassche@google.com>
This commit is contained in:
parent
633b9ba26b
commit
c41a4826d1
1 changed files with 2 additions and 2 deletions
|
@ -24,8 +24,8 @@ namespace init {
|
|||
ServiceList::ServiceList() {}
|
||||
|
||||
ServiceList& ServiceList::GetInstance() {
|
||||
static ServiceList instance;
|
||||
return instance;
|
||||
static ServiceList* instance = new ServiceList;
|
||||
return *instance;
|
||||
}
|
||||
|
||||
size_t ServiceList::CheckAllCommands() {
|
||||
|
|
Loading…
Reference in a new issue