|
|
@@ -445,6 +445,9 @@ bool FindGuardianPid(CAutoArray<int> &pIDArr)
|
|
|
return false;
|
|
|
}
|
|
|
#endif //RVC_OS_LINUX
|
|
|
+
|
|
|
+
|
|
|
+//TODO: CrossPlaform [Gifur@2025630]
|
|
|
int CHealthManagerEntity::CheckGuardianIsRun(bool bStart)
|
|
|
{
|
|
|
#ifdef RVC_OS_WIN
|
|
|
@@ -543,6 +546,8 @@ int CHealthManagerEntity::CheckGuardianIsRun(bool bStart)
|
|
|
}
|
|
|
#endif //RVC_OS_WIN
|
|
|
}
|
|
|
+
|
|
|
+//TODO: CrossPlaform [Gifur@2025630]
|
|
|
bool CHealthManagerEntity::StopGuardian()
|
|
|
{
|
|
|
#ifdef RVC_OS_WIN
|
|
|
@@ -1418,34 +1423,6 @@ void CHealthManagerEntity::WarnAndRestartFunc(RebootTriggerEnum eTrigger, Reboot
|
|
|
m_fsm.QuitFrameworkAndSaveInfo(eTrigger, eWay);
|
|
|
}
|
|
|
|
|
|
-namespace
|
|
|
-{
|
|
|
-
|
|
|
- ErrorCodeEnum SplitAdapterFileName(CSimpleStringA strFileName, CAutoArray<CSimpleStringA>& values)
|
|
|
- {
|
|
|
-#ifdef RVC_OS_WIN
|
|
|
- CSimpleStringA strPrefix("");
|
|
|
- CSimpleStringA strSuffix(".dll");
|
|
|
-#else
|
|
|
- CSimpleStringA strPrefix("lib");
|
|
|
- CSimpleStringA strSuffix(".so");
|
|
|
-#endif //RVC_OS_WIN
|
|
|
-
|
|
|
- if (strFileName.GetLength() < strPrefix.GetLength() + strSuffix.GetLength()) {
|
|
|
- return Error_Param;
|
|
|
- }
|
|
|
-
|
|
|
- CSimpleStringA pureAdapterName = strFileName.SubString(
|
|
|
- strPrefix.GetLength(), strFileName.GetLength() - strPrefix.GetLength() - strSuffix.GetLength());
|
|
|
-
|
|
|
- values = pureAdapterName.Split('.');
|
|
|
- if (values.GetCount() != 4) {
|
|
|
- return Error_DataCheck;
|
|
|
- }
|
|
|
- return Error_Succeed;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
void CHealthManagerEntity::OnEntityStateHook(const char* pszEntityName, const char* pszTriggerEntity, EntityStateEnum eState, EntityStateEnum eLastState)
|
|
|
{
|
|
|
if (m_fsm.CheckIsRebooting())//oilyang@20250415 no need to process entity state changing event while in rebooting
|