mirror of
https://gitee.com/openharmony/communication_wifi.git
synced 2024-12-19 21:07:25 +00:00
bugfix for crash test
Signed-off-by: yanxiaotao@huawei.com <yanxiaotao@huawei.com>
This commit is contained in:
parent
ccdbedbd11
commit
69494bfcbb
@ -171,7 +171,7 @@ void WifiDeviceStub::RemoveDeviceCbDeathRecipient(void)
|
||||
void WifiDeviceStub::RemoveDeviceCbDeathRecipient(const wptr<IRemoteObject> &remoteObject)
|
||||
{
|
||||
WIFI_LOGI("RemoveDeathRecipient, remoteObject: %{public}p!", &remoteObject);
|
||||
WIFI_LOGI("RemoveDeathRecipient, remoteObject.promote: 0x%{public}x!", remoteObject.promote());
|
||||
WIFI_LOGI("RemoveDeathRecipient, remoteObject.promote: %{public}p!", static_cast<void*>(remoteObject.promote()));
|
||||
std::lock_guard<std::mutex> lock(mutex_);
|
||||
RemoteDeathMap::iterator iter = remoteDeathMap.find(remoteObject.promote());
|
||||
if (iter == remoteDeathMap.end()) {
|
||||
@ -789,7 +789,8 @@ void WifiDeviceStub::OnRegisterCallBack(uint32_t code, MessageParcel &data, Mess
|
||||
#else
|
||||
deathRecipient_ = new (std::nothrow) WifiDeathRecipient(*this);
|
||||
remoteDeathMap.insert(std::make_pair(remote, deathRecipient_));
|
||||
WIFI_LOGI("OnRegisterCallBack, add deathRecipient: 0x%{public}x", remote);
|
||||
WIFI_LOGI("OnRegisterCallBack, add deathRecipient, remote: %{public}p",
|
||||
static_cast<void*>(remote));
|
||||
#endif
|
||||
}
|
||||
if ((remote->IsProxyObject()) && (!remote->AddDeathRecipient(deathRecipient_))) {
|
||||
|
@ -21,7 +21,7 @@ namespace OHOS {
|
||||
namespace Wifi {
|
||||
void WifiScanDeathRecipient::OnRemoteDied(const wptr<IRemoteObject>& remoteObject)
|
||||
{
|
||||
WIFI_LOGD("WifiScanDeathRecipient::OnRemoteDied!");
|
||||
WIFI_LOGI("WifiScanDeathRecipient::OnRemoteDied! remoteObject: %{public}p", &remoteObject);
|
||||
WifiInternalEventDispatcher::GetInstance().RemoveScanCallback(remoteObject.promote());
|
||||
}
|
||||
} // namespace Wifi
|
||||
|
Loading…
Reference in New Issue
Block a user