diff --git a/ipc/native/src/core/source/ipc_process_skeleton.cpp b/ipc/native/src/core/source/ipc_process_skeleton.cpp index 5b3bdee61e556acce3c0e4ecf8f837baeab07dab..ef22626a76963c83609da662dff0527ba6ed045c 100644 --- a/ipc/native/src/core/source/ipc_process_skeleton.cpp +++ b/ipc/native/src/core/source/ipc_process_skeleton.cpp @@ -234,6 +234,7 @@ bool IPCProcessSkeleton::OnThreadTerminated(const std::string &threadName) bool IPCProcessSkeleton::IsContainsObject(IRemoteObject *object) { /* don't care mutex result even object is deleted */ + std::lock_guard lock(mutex_); auto it = isContainStub_.find(object); if (it != isContainStub_.end()) { return it->second;