ResourceWatcherFSM.h 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552
  1. #pragma once
  2. #include "stdafx.h"
  3. #include "SpFSM.h"
  4. #include "CommEntityUtil.hpp"
  5. #define JUS_A_TEST 0
  6. #include "FileInfo.h"
  7. #include <iostream>
  8. #include <iomanip>
  9. #include <fstream>
  10. #include <stdarg.h>
  11. #include <string>
  12. #include <vector>
  13. #include <assert.h>
  14. #include <time.h>
  15. #include <map>
  16. #include <vector>
  17. #include <unordered_map>
  18. #if defined(RVC_OS_LINUX)
  19. #include <sys/sysinfo.h>
  20. #include <time.h>
  21. #include <sys/types.h>
  22. #include <dirent.h>
  23. #include <sys/stat.h>
  24. #include "CommEntityUtil.hpp"
  25. #else
  26. #include <ws2tcpip.h>
  27. #include <tchar.h>
  28. #include <WinCrypt.h>
  29. #include <atlbase.h>
  30. #include <conio.h>
  31. #include "mbnapi.h"
  32. #include <comdef.h>
  33. #include "ResourceWatcher_UserCode.h"
  34. #include <time.h>
  35. #endif //RVC_OS_LINUX
  36. using namespace std;
  37. #define SYSVAR_FRAMEWORK_FIRST_BOOT "FirstLaunchSinceSysBoot" //框架开机后首次启动标识
  38. #define SYSVAR_FRAMEWORK_FIRST_BOOT_YES "Y"
  39. #define SYSVAR_FRAMEWORK_FIRST_BOOT_NO "N"
  40. //硬件信息搜集参数
  41. #define DEFAULT_HARDWARE_CHECK_TIME 60 * 1000 //CPU、内存扫描默认间隔,1分钟
  42. #define TIMER_HARDWARE_CHECK 2
  43. //硬盘扫描
  44. #define DEFAULT_DISK_CHECK_TIME 4 * 60 * 60 * 1000 //硬盘默认4小时扫描一次
  45. #define TIMER_DISK_CHECK 33
  46. //保留版本数目
  47. #define DEFAULT_VERSION_SAVED_COUNT 5
  48. #define MAX_VERSION_PATH 256
  49. //一天的秒数,用于计算文件时间
  50. const int SECONDS_OF_DAY = 60 * 60 * 24;
  51. const int VIDEO_DEFAULT_BACKDAYS = 30;
  52. enum EvtType
  53. {
  54. USER_EVT_RUN = EVT_USER + 1
  55. };
  56. #include "ResourceWatcher_server_g.h"
  57. #include "ResourceWatcher_msg_g.h"
  58. using namespace ResourceWatcher;
  59. #define MOD_VERSION "1.0.0.0"
  60. struct CInstallInfoEx : public CInstallInfo
  61. {
  62. CInstallInfoEx(const CInstallInfo& info)
  63. :CInstallInfo(info)
  64. {
  65. /* empty */
  66. }
  67. bool operator < (const CInstallInfoEx& rhs) const
  68. {
  69. CVersion l_version(this->InstallVersion);
  70. DWORD l_timeTick = (DWORD)this->tmSwithOverDate;
  71. CVersion r_version(rhs.InstallVersion);
  72. DWORD r_timeTick = (DWORD)rhs.tmSwithOverDate;
  73. if (l_version == r_version)
  74. return l_timeTick <= r_timeTick;
  75. return l_version > r_version;
  76. }
  77. };
  78. template<class T>
  79. class TimerOutHelper : public ITimerListener
  80. {
  81. public:
  82. typedef void (T::* FuncTimer)(void* pUserdata);
  83. TimerOutHelper(T* p, FuncTimer pTimerFunc, void* pData, bool bDeleteSelf = false)
  84. : m_pObject(p), m_pUserData(pData), m_pTimer(pTimerFunc), m_bDeleteSelf(bDeleteSelf)
  85. {
  86. }
  87. virtual void OnTimeout(DWORD dwTimerID)
  88. {
  89. (m_pObject->*m_pTimer)(m_pUserData);
  90. if (m_bDeleteSelf)
  91. delete this;
  92. }
  93. private:
  94. void* m_pUserData;
  95. T* m_pObject;
  96. FuncTimer m_pTimer;
  97. bool m_bDeleteSelf;
  98. };
  99. #ifdef RVC_OS_LINUX
  100. //chenjilin hardware change
  101. typedef struct CPUInfoStruct
  102. { // 记录 /proc/stat 中的CPU信息
  103. char name[20];
  104. unsigned int user;
  105. unsigned int nice;
  106. unsigned int system;
  107. unsigned int idle;
  108. unsigned int lowait;
  109. unsigned int irq;
  110. unsigned int softirq;
  111. }CPUInfo;
  112. typedef struct ProcCPUInfoStruct {
  113. unsigned int pid;
  114. char pname[1024];
  115. unsigned long utime; //user time
  116. unsigned long stime; //kernel time
  117. unsigned long cutime; //all user time
  118. unsigned long cstime; //all dead time
  119. }ProcCPUInfo;
  120. typedef struct MemInfoStruct // 记录 /proc/meminfo 中的内存信息
  121. {
  122. char infoName1[20];
  123. unsigned long memTotal;
  124. char infoName2[20];
  125. unsigned long memFree;
  126. char infoName3[20];
  127. unsigned long memAvail;
  128. }MemInfo;
  129. //change end
  130. #else
  131. struct EntityRunInfo
  132. {
  133. bool bGetLoadOpt;
  134. bool bRestarting;
  135. int eState;
  136. int eTest;
  137. int loadOpt;
  138. int memoryHighCount;
  139. int cpuRatio;
  140. FILETIME prevSysKernel, prevSysUser;
  141. FILETIME prevProcKernel, prevProcUser;
  142. };
  143. struct CPUInforStruct {
  144. bool bInitialed;
  145. int level;
  146. CSimpleStringA csBrand;
  147. };
  148. #endif // RVC_OS_LINUX
  149. struct SystemBasicInfo
  150. {
  151. CSimpleStringA strManufacturer;
  152. CSimpleStringA strProductName;
  153. CSimpleStringA strSerialNumber;
  154. SystemBasicInfo():strManufacturer(true), strProductName(true), strSerialNumber(true) {}
  155. };
  156. struct DeleteParam
  157. {
  158. DeleteParam():path(true),delDirFlag(false), saveBackDay(0), rtaCode(true), logCode(true) {}
  159. DeleteParam(LPCTSTR lpszPath):path(lpszPath), delDirFlag(false), saveBackDay(0), rtaCode(true), logCode(true) {}
  160. DeleteParam(const DeleteParam& rhs) :path(rhs.path), delDirFlag(rhs.delDirFlag), saveBackDay(rhs.saveBackDay), rtaCode(rhs.rtaCode), logCode(rhs.logCode) {}
  161. void SetRmDirFlag(bool val = true) {
  162. delDirFlag = val;
  163. if (delDirFlag) saveBackDay = 0;
  164. }
  165. //lpszPath:清理路径
  166. CSimpleStringA path;
  167. //控制是否将目录也一并删除,false 保留目录, true 删除目录
  168. bool delDirFlag;
  169. //保存多少天内的文件, 默认参数,默认值为0,即不保存。(delDir = true时,该参数强制为0)
  170. bool saveBackDay;
  171. CSimpleStringA rtaCode;
  172. CSimpleStringA logCode;
  173. };
  174. struct DeleteResult
  175. {
  176. DeleteResult() :sucCnt(0), failCnt(0) {}
  177. //删除成功个数
  178. DWORD sucCnt;
  179. //删除失败个数
  180. DWORD failCnt;
  181. };
  182. class ResourceWatcherFSM : public FSMImpl<ResourceWatcherFSM>
  183. {
  184. public:
  185. ResourceWatcherFSM(void);
  186. ~ResourceWatcherFSM(void);
  187. enum { s0, s1, s2, s3 };
  188. BEGIN_FSM_STATE(ResourceWatcherFSM)
  189. FSM_STATE_ENTRY(s0, "Idle", s0_on_entry, s0_on_exit, s0_on_event)
  190. FSM_STATE_ENTRY(s1, "Running", s1_on_entry, s1_on_exit, s1_on_event)
  191. END_FSM_STATE()
  192. BEGIN_FSM_RULE(ResourceWatcherFSM, s0)
  193. FSM_RULE_ENTRY(s0, s1, USER_EVT_RUN, 0)
  194. END_FSM_RULE()
  195. virtual ErrorCodeEnum OnInit();
  196. virtual ErrorCodeEnum OnExit();
  197. //进入首页时触发的功能在此
  198. void TriggerAtStatusChanged(bool bMStatus);
  199. void TriggerProccessUpload();
  200. void AfterInit();
  201. virtual void s0_on_entry();
  202. virtual void s0_on_exit();
  203. virtual unsigned int s0_on_event(FSMEvent* e);
  204. virtual void s1_on_entry();
  205. virtual void s1_on_exit();
  206. virtual unsigned int s1_on_event(FSMEvent* e);
  207. void SelfTest(EntityTestEnum eTestType, CSmartPointer<ITransactionContext> pTransactionContext);
  208. BOOL IsFirstRunAfterBoot() const
  209. {
  210. return m_bFirstRunAfterBoot;
  211. }
  212. #ifdef RVC_OS_LINUX
  213. bool GetMonitorInfo(CSimpleStringA& outInfo);
  214. bool GetSysActiveStatus(CSimpleStringA& outInfo);
  215. #else
  216. void SetForceDiskCheckFlag(bool flag)
  217. {
  218. m_bNeedForceDiskCheck = flag;
  219. }
  220. #endif // RVC_OS_LINUX
  221. void DetectSoftwareInstallStatus();
  222. private:
  223. int m_cpuTop; // CPU资源消耗最高的top进程个数
  224. CSystemStaticInfo m_RvcSysinfo;
  225. BOOL m_bFirstRunAfterBoot;
  226. int m_diskLastWarnHour;
  227. BOOL m_skipDesktopDetect;
  228. #ifdef RVC_OS_WIN
  229. vector<CSimpleStringA>m_nonSignedFiles;
  230. int m_iNonSignedTotal;
  231. bool m_bNeedForceDiskCheck;
  232. string sysProcName = "[System Process]|System|Registry|smss.exe|csrss.exe|services.exe|wininit.exe";
  233. #endif // RVC_OS_WIN
  234. unordered_map<int, long long> oldProcessTime; // <pid, 旧时刻进程的CPU占用时间>
  235. unordered_map<int, long long> newProcessTime; // <pid, 新时刻进程的CPU占用时间>
  236. unordered_map<int, CSimpleStringA> processName; // <pid, 进程名>
  237. unordered_map<int, double> processCpu; // <pid, CPU占用率>
  238. int m_iVerify;
  239. int m_iNonSignedDisplay;
  240. int m_cpuHighPercent, m_memHighPercent, m_diskHighPercent;
  241. BOOL checkActiveBefore;
  242. BOOL neverMainPage;
  243. BOOL forceFileOpt;
  244. std::vector<std::string> keyUserlist;
  245. std::vector<std::string> keyPublist;
  246. BOOL flag4DeleteKeyAutoStartFile;
  247. BOOL flag4DoAutoStartTaskIgnoreBoot;
  248. CSimpleStringA m_strLoginedUserName;
  249. map<string, string> SysProcInfo; //用于记录系统进程
  250. public:
  251. void CheckDiskFileSpace();
  252. ErrorCodeEnum BizLinkDetect(
  253. SpReqAnsContext<ResourceWatcherService_BizLinkDetect_Req,
  254. ResourceWatcherService_BizLinkDetect_Ans>::Pointer ctx);
  255. ErrorCodeEnum CheckNetType(
  256. SpReqAnsContext<ResourceWatcherService_CheckNetType_Req,
  257. ResourceWatcherService_CheckNetType_Ans>::Pointer ctx);
  258. ErrorCodeEnum GetBizLinks(
  259. SpReqAnsContext<ResourceWatcherService_GetBizLinks_Req,
  260. ResourceWatcherService_GetBizLinks_Ans>::Pointer ctx);
  261. bool GetNeverMainPageFlag() { return neverMainPage; } //是否未进过首页
  262. void GetSystemProccess();
  263. void GetSystemCPUStatus();
  264. void GetSystemMemoryStatus();
  265. void GetSystemDiskStatus();
  266. void GetDiskStatusFrom(LPCTSTR path);
  267. void HardwareInfoTimer(void* pData);
  268. void DiskCheckTimer(void* pData);
  269. void LinkDetect(int detectType, const char* url, bool& status, unsigned int& delay, int warnFlag = 1);
  270. time_t GetPathTimeSeconds(const char* inPath);
  271. void AutoDeleteFiles();
  272. void CenterSettingDelete();
  273. BOOL DeleteVersionPackage();
  274. void DeleteVideoFiles();
  275. int ProcessFileDelete(const DeleteParam& delParam, DeleteResult& delResult);
  276. BOOL DetectIsFirstRunAtBoot();
  277. #ifdef RVC_OS_LINUX
  278. /** 返回操作系统当前的版本,比如1032,1010,1031*/
  279. UINT GetSystemDisplayVersion(CSimpleStringA& strVersion);
  280. void UploadSysVersionInfo(UINT& ver);
  281. void UploadSysActivationStatus();
  282. string MemoryProcessStatus();
  283. long GetCPURunTime(CPUInfo* cpu);
  284. long ReadProcCPURunTime(DWORD pid, ProcCPUInfo* pInfo);
  285. const char* GetItems(const char* buffer, unsigned int item);
  286. void ConfirmWindowEffectHasBeenOpen();
  287. void switchWindowsEffect(const char* cfgFilePath, bool enable);
  288. /** 1032操作系统版本出现剪贴板和操作中心,需要将剪贴板关掉避免手势唤起
  289. * 统信的人告知可以通过删除剪贴板程序实现……JUST DO IT!
  290. */
  291. void ConfirmDDEClipboardDisable();
  292. void RecoverDDEClipboardEnable();
  293. /** 自己摸索,统信说需要操作系统定制方能解决 [Gifur@202198]*/
  294. void ConfirmNotificationCenterDisable();
  295. #else
  296. int GetCpuUsageRatio(int pid);
  297. ULONGLONG GetDiskUsedByte();
  298. bool GetVTMExePath(CSimpleStringA& strValue, bool FailIfNotExist);
  299. bool CopyExeToRoot(const CSimpleStringA& csVersion, const CSimpleStringA& aimExePath);
  300. bool RegOperation4LnkFile();
  301. bool RegRdVtmVersion(CSimpleStringA& VTMpath, CSimpleStringA& vtmVersion, CSimpleStringA& verPath);
  302. bool RegWtVtmPath(const CSimpleStringA& vtmExtPath, const CSimpleStringA& rootPath);
  303. bool RegWtVtmVersion(const CSimpleStringA& vtmVer);
  304. //nType: 0 桌面,2 启动列表
  305. ErrorCodeEnum CreateLink(int nType, const CSimpleStringA& exePath);
  306. ErrorCodeEnum CreateLinkFile(const CSimpleStringA& szStartAppPath, const CSimpleStringA& szAddCmdLine,
  307. const CSimpleStringA& szDestLnkPath, const CSimpleStringA& szIconPath);
  308. bool GetVtmVersionFromActiveTxt(CSimpleStringA& csVersion);
  309. bool GetRegValueInt(HKEY hKey, LPCTSTR lpcszParam, DWORD& DwValue);
  310. bool GetRegValue(HKEY hKey, LPCTSTR lpcszParam, CSimpleStringA& strValue);
  311. void DetectAutoStartupCover();
  312. void UploadScreenInfo();
  313. //0:explorer.exe
  314. //1:vbs
  315. //2:vtm.exe
  316. //3:startmenu lnk from RVCTermimalApplicationSetup
  317. //4:startmenu lnk from install scripts
  318. //5:startmenu lnk from user customization
  319. //-1:failed
  320. int DetectAutoStartupType(CSimpleStringA& strValue);
  321. ErrorCodeEnum ChangeAutoStartupWithExe(bool resetVBS = false, bool resetExplorer = false);
  322. int InitialAutoStartupSetType();
  323. void DeleteDuplicateAutoStartFile(bool toDeleteLastLegity = false);
  324. //0:startmenu lnk from RVCTermimalApplicationSetup
  325. //1:startmenu lnk from install scripts
  326. //2:startmenu lnk from user customization
  327. BOOL IsHasSetAutoStartupByFolder(CSimpleStringA& strPath, int& setType);
  328. void DetectVersionHasChangedAndWarn();
  329. bool SetDesktopSysIcon2Registry(const std::string& key, bool toDisplay);
  330. void MakeSureWin8IntoDesktopPageAtLogon();
  331. void DetectVersionHasChangedAndWarnCover()
  332. {
  333. if (!checkActiveBefore) {
  334. DetectVersionHasChangedAndWarn();
  335. checkActiveBefore = TRUE;
  336. }
  337. }
  338. void VerifySignature();
  339. void VerifySignature(const CSimpleStringA& filePath);
  340. CSimpleStringA GetFileName(const CSimpleStringA& filePath);
  341. bool RetrieveDigitalSignatureInfo(const char* pFilePath);
  342. bool VerifyFirstCertificate(HCERTSTORE hStore, PCMSG_SIGNER_INFO pSignerInfo);
  343. bool VerifyOtherCertificate(PCMSG_SIGNER_INFO pSignerInfo);
  344. void DetectWallpaperAndWarn();
  345. void InitCustomAutoStartFileSheet();
  346. void InitUserInfo();
  347. void ToListCurrentUserStartupFile(const std::string& userDirPath, std::vector<std::string>& files, std::vector<std::string>& keyfiles);
  348. void GetCommDesktopDirectory(CSimpleStringA& outDir);
  349. void GetUserDesktopDirectory(CSimpleStringA& outDir);
  350. bool IsDesktopIconExist(CSimpleStringA& strPath);
  351. void GetCommStartupDirectory(CSimpleStringA& outDir);
  352. void GetUserStartupDirectory(CSimpleStringA& outDir);
  353. bool IsStartupIconExist(CSimpleStringA& strPath);
  354. void GetAutoStartFile(std::string& userDirPath, std::vector<std::string>& userDirFiles, std::string& pubDirPath, std::vector<std::string>& pubDirFiles);
  355. #endif // RVC_OS_LINUX
  356. void AlarmSystemBasicInfo();
  357. ErrorCodeEnum CatchSystemBasicInfo(SystemBasicInfo& info);
  358. /*
  359. -1:入参无效
  360. -2:GetPath失败
  361. >0:返回原字符串中$()后的字符位置,outDir返回解析后的内容
  362. */
  363. int ExpandDir(LPCTSTR macorStr, CSimpleStringA& outDir);
  364. };
  365. class RunEvent : public FSMEvent
  366. {
  367. public:
  368. RunEvent() : FSMEvent(USER_EVT_RUN) {}
  369. virtual ~RunEvent() {}
  370. };
  371. struct DetectSoftwareInstallStatusTask : public ITaskSp
  372. {
  373. ResourceWatcherFSM* m_pFSM;
  374. DetectSoftwareInstallStatusTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  375. void Process()
  376. {
  377. m_pFSM->DetectSoftwareInstallStatus();
  378. }
  379. };
  380. #ifdef RVC_OS_LINUX
  381. struct AggerateAutoStatTask : public ITaskSp
  382. {
  383. ResourceWatcherFSM* m_pFSM;
  384. AggerateAutoStatTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  385. void Process()
  386. {
  387. m_pFSM->UploadSysActivationStatus();
  388. }
  389. };
  390. #else
  391. struct CreateLinkTask :public ITaskSp
  392. {
  393. ResourceWatcherFSM* m_pFSM;
  394. CreateLinkTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  395. void Process()
  396. {
  397. m_pFSM->RegOperation4LnkFile();
  398. }
  399. };
  400. struct VerifyDigitSignTask : public ITaskSp
  401. {
  402. ResourceWatcherFSM* m_pFSM;
  403. VerifyDigitSignTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  404. void Process()
  405. {
  406. m_pFSM->VerifySignature();
  407. }
  408. };
  409. struct AggerateAutoStatTask : public ITaskSp
  410. {
  411. ResourceWatcherFSM* m_pFSM;
  412. AggerateAutoStatTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  413. void Process()
  414. {
  415. m_pFSM->UploadScreenInfo();
  416. m_pFSM->DetectWallpaperAndWarn();
  417. m_pFSM->DetectAutoStartupCover();
  418. m_pFSM->RegOperation4LnkFile();
  419. m_pFSM->MakeSureWin8IntoDesktopPageAtLogon();
  420. }
  421. };
  422. #endif // RVC_OS_LINUX
  423. //终端版本默认的自动清理策略
  424. struct DiskAndFilesTask : public ITaskSp
  425. {
  426. ResourceWatcherFSM* m_pFSM;
  427. int checkTime;
  428. bool flag = false;
  429. DiskAndFilesTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  430. void Process()
  431. {
  432. m_pFSM->AutoDeleteFiles();
  433. m_pFSM->CenterSettingDelete();
  434. if (flag)
  435. {
  436. m_pFSM->GetSystemDiskStatus(); //仅启动时检测一次硬盘状态即可
  437. void* pTmpData = NULL;
  438. ITimerListener* pListener = new TimerOutHelper<ResourceWatcherFSM>(m_pFSM, &ResourceWatcherFSM::DiskCheckTimer, pTmpData);
  439. m_pFSM->GetEntityBase()->GetFunction()->SetTimer(TIMER_DISK_CHECK, pListener, checkTime);
  440. DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("Set DISK CHECK Timer!");
  441. }
  442. }
  443. };
  444. struct CheckDiskFileSpaceTask : public ITaskSp
  445. {
  446. ResourceWatcherFSM* m_pFSM;
  447. CheckDiskFileSpaceTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  448. void Process()
  449. {
  450. m_pFSM->CheckDiskFileSpace();
  451. }
  452. };
  453. //获取系统进程并上送, TerminalStage的值为 A, C, M, S触发
  454. struct UploadSysProcInfoTask : public ITaskSp
  455. {
  456. ResourceWatcherFSM* m_pFSM;
  457. UploadSysProcInfoTask(ResourceWatcherFSM* pFSM) : m_pFSM(pFSM) {}
  458. void Process()
  459. {
  460. CSimpleStringA t_terminalState;
  461. DWORD elapsed = 0;
  462. DWORD dwStart = SP::Module::Comm::RVCGetTickCount();
  463. DWORD dwEnd = SP::Module::Comm::RVCGetTickCount();
  464. DWORD checkTimeOut = 5 * 60000; //五分钟超时
  465. while (elapsed < checkTimeOut && m_pFSM->GetNeverMainPageFlag()) //到达终态,5分钟未进首页 or 成功进入首页跳出循环
  466. {
  467. Sleep(60000); //1分钟检测一次进首页状态
  468. dwEnd = SP::Module::Comm::RVCGetTickCount();
  469. elapsed = dwEnd - dwStart;
  470. }
  471. m_pFSM->GetSystemCPUStatus();
  472. m_pFSM->GetSystemProccess();
  473. }
  474. };