mirror of
https://gitee.com/openharmony/communication_ipc
synced 2024-11-27 01:51:13 +00:00
fix:Change the function name CheckInstanceIsExiting to CheckInstanceException
Signed-off-by: weimengxue <weimengxue1@h-partners.com>
This commit is contained in:
parent
d5e6822168
commit
9b73f703cd
@ -54,7 +54,7 @@ public:
|
||||
|
||||
static bool UpdateSendRequestCount(int delta);
|
||||
|
||||
static bool CheckInstanceIsExiting(std::atomic<uint32_t> &flag);
|
||||
static bool IsInstanceException(std::atomic<uint32_t> &flag);
|
||||
|
||||
bool IsSendRequesting();
|
||||
|
||||
|
@ -109,7 +109,7 @@ void IPCThreadSkeleton::SaveThreadName(const std::string &name)
|
||||
if (current == nullptr) {
|
||||
return;
|
||||
}
|
||||
if (CheckInstanceIsExiting(current->exitFlag_)) {
|
||||
if (IsInstanceException(current->exitFlag_)) {
|
||||
return;
|
||||
}
|
||||
current->threadName_ = name;
|
||||
@ -123,7 +123,7 @@ IPCThreadSkeleton *IPCThreadSkeleton::GetCurrent()
|
||||
void *curTLS = pthread_getspecific(TLSKey_);
|
||||
if (curTLS != nullptr) {
|
||||
current = reinterpret_cast<IPCThreadSkeleton *>(curTLS);
|
||||
if (CheckInstanceIsExiting(current->exitFlag_)) {
|
||||
if (IsInstanceException(current->exitFlag_)) {
|
||||
return nullptr;
|
||||
}
|
||||
GetVaildInstance(current);
|
||||
@ -167,7 +167,7 @@ IPCThreadSkeleton::~IPCThreadSkeleton()
|
||||
}
|
||||
}
|
||||
|
||||
bool IPCThreadSkeleton::CheckInstanceIsExiting(std::atomic<uint32_t> &flag)
|
||||
bool IPCThreadSkeleton::IsInstanceException(std::atomic<uint32_t> &flag)
|
||||
{
|
||||
if (flag == INVOKER_USE_MAGIC) {
|
||||
return false;
|
||||
@ -193,7 +193,7 @@ IRemoteInvoker *IPCThreadSkeleton::GetRemoteInvoker(int proto)
|
||||
if (current == nullptr) {
|
||||
return nullptr;
|
||||
}
|
||||
if (CheckInstanceIsExiting(current->exitFlag_)) {
|
||||
if (IsInstanceException(current->exitFlag_)) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
@ -286,7 +286,7 @@ bool IPCThreadSkeleton::UpdateSendRequestCount(int delta)
|
||||
if (current == nullptr) {
|
||||
return false;
|
||||
}
|
||||
if (CheckInstanceIsExiting(current->exitFlag_)) {
|
||||
if (IsInstanceException(current->exitFlag_)) {
|
||||
return false;
|
||||
}
|
||||
current->sendRequestCount_ += delta;
|
||||
|
@ -70,7 +70,7 @@ bool BrokerRegistration::Register(const std::u16string &descriptor, const Constr
|
||||
for (; iter != objects_.end();) {
|
||||
std::string soPath = GetObjectSoPath(iter->first);
|
||||
if (soPath.empty() || (soPath != iter->second)) {
|
||||
ZLOGW(LABEL, "path:%{public}s is dlcosed", iter->second.c_str());
|
||||
ZLOGW(LABEL, "path:%{public}s is dlclosed", iter->second.c_str());
|
||||
iter = objects_.erase(iter);
|
||||
continue;
|
||||
}
|
||||
@ -109,7 +109,7 @@ void BrokerRegistration::Unregister(const std::u16string &descriptor)
|
||||
for (auto iter = objects_.begin(); iter != objects_.end();) {
|
||||
std::string soPath = GetObjectSoPath(iter->first);
|
||||
if (soPath.empty() || (soPath != iter->second)) {
|
||||
ZLOGW(LABEL, "path:%{public}s is dlcosed", iter->second.c_str());
|
||||
ZLOGW(LABEL, "path:%{public}s is dlclosed", iter->second.c_str());
|
||||
iter = objects_.erase(iter);
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user