mirror of
https://gitee.com/openharmony/communication_wifi.git
synced 2024-11-23 15:10:16 +00:00
modify max wait time to 30 seconds to auto start service
Signed-off-by: junxinlu <lujunxin@huawei.com>
This commit is contained in:
parent
ad992b1733
commit
4a5031e509
@ -1,4 +1,4 @@
|
||||
# Copyright (C) 2022-2022 Huawei Device Co., Ltd.
|
||||
# Copyright (C) 2022 Huawei Device Co., Ltd.
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Copyright (C) 2022-2022 Huawei Device Co., Ltd.
|
||||
# Copyright (C) 2022 Huawei Device Co., Ltd.
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
|
@ -1074,7 +1074,7 @@ ErrCode WifiDeviceProxy::RegisterCallBack(const std::shared_ptr<IWifiDeviceCallB
|
||||
WIFI_LOGD("RegisterCallBack start!");
|
||||
int ret = RegisterIpcCallback(AsyncCallback, ONCE, IPC_WAIT_FOREVER, &svcIdentity_, nullptr);
|
||||
if (ret != 0) {
|
||||
WIFI_LOGE("[WifiScanProxy] RegisterIpcCallback failed");
|
||||
WIFI_LOGE("RegisterIpcCallback failed");
|
||||
return WIFI_OPT_FAILED;
|
||||
}
|
||||
|
||||
@ -1223,4 +1223,4 @@ void WifiDeviceProxy::OnRemoteDied(void)
|
||||
g_deviceCallBackStub.SetRemoteDied(true);
|
||||
}
|
||||
} // namespace Wifi
|
||||
} // namespace OHOS
|
||||
} // namespace OHOS
|
||||
|
@ -101,7 +101,7 @@ void WifiManager::AutoStartStaServiceThread(void)
|
||||
struct dirent *dent = nullptr;
|
||||
int currentWaitTime = 0;
|
||||
const int sleepTime = 1;
|
||||
const int maxWaitTimes = 10;
|
||||
const int maxWaitTimes = 30;
|
||||
|
||||
dir = opendir("/sys/class/net");
|
||||
if (dir == nullptr) {
|
||||
|
Loading…
Reference in New Issue
Block a user