Skip to content

Commit

Permalink
Avoid deallocating hwsm statics during shutdown. am: c63f032
Browse files Browse the repository at this point in the history
Change-Id: I90baec1f7abe417de164e31525afe32a85194618
  • Loading branch information
smore-lore authored and android-build-merge-worker-robot committed Apr 22, 2020
2 parents a4d34a8 + c63f032 commit 441c5d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions transport/ServiceManagement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,8 @@ sp<IServiceManager1_2> defaultServiceManager1_2() {
using android::hidl::manager::V1_2::BnHwServiceManager;
using android::hidl::manager::V1_2::BpHwServiceManager;

static std::mutex gDefaultServiceManagerLock;
static sp<IServiceManager1_2> gDefaultServiceManager;
static std::mutex& gDefaultServiceManagerLock = *new std::mutex;
static sp<IServiceManager1_2>& gDefaultServiceManager = *new sp<IServiceManager1_2>;

{
std::lock_guard<std::mutex> _l(gDefaultServiceManagerLock);
Expand Down

0 comments on commit 441c5d6

Please sign in to comment.