|
@@ -393,8 +393,11 @@ void CSATDevices::GetCurrentDevices(std::vector<SATDEV::STDevice> &vtDevices)
|
|
|
stDevice.nStatus = SATDEV::Online;
|
|
|
else if ( (npos = it->find(" offline")) != std::string::npos )
|
|
|
stDevice.nStatus = SATDEV::Offline;
|
|
|
- else if ( (npos = it->find(" unauthorized")) != std::string::npos ) // 未认证也做为离线的一种;
|
|
|
- stDevice.nStatus = SATDEV::Offline;
|
|
|
+ else if ( (npos = it->find("unauthorized")) != std::string::npos ) // 未认证也做为离线的一种;
|
|
|
+ {
|
|
|
+ stDevice.nStatus = SATDEV::Unauthorized;
|
|
|
+ GLOBAL::WriteTextLog("找到unauthorized状态的设备");
|
|
|
+ }
|
|
|
// 获取设备名;
|
|
|
stDevice.strName = it->substr(0, npos);
|
|
|
// 如果是网络,去掉5555;
|
|
@@ -463,6 +466,8 @@ void CSATDevices::SaveDeviceStatus2Config(SATDEV::STDevice &stDevice)
|
|
|
WritePrivateProfileString(_T("ADBSTATUS"), stDevice.strName.c_str(), _T("Offline"), GLOBAL::g_szPython27ResourceConfig);
|
|
|
else if ( stDevice.nStatus == SATDEV::Dropline )
|
|
|
WritePrivateProfileString(_T("ADBSTATUS"), stDevice.strName.c_str(), _T("Dropline"), GLOBAL::g_szPython27ResourceConfig);
|
|
|
+ else if ( stDevice.nStatus == SATDEV::Unauthorized)
|
|
|
+ WritePrivateProfileString(_T("ADBSTATUS"), stDevice.strName.c_str(), _T("Unauthorized"), GLOBAL::g_szPython27ResourceConfig);
|
|
|
}
|
|
|
|
|
|
void CSATDevices::SaveAllDevicesStatus2Config()
|