Lines Matching refs:cmd
73 bool HdcClient::StartKillServer(const char *cmd, bool startOrKill) in StartKillServer() argument
85 if (!strstr(cmd, " -r")) { in StartKillServer()
107 if (!strstr(cmd, " -r")) { in StartKillServer()
209 void HdcClient::RunCommandWin32(const string& cmd) in RunCommandWin32() argument
238 const char *msg = cmd.c_str(); in RunCommandWin32()
259 void HdcClient::RunCommand(const string& cmd) in RunCommand() argument
262 procFileInfo = popen(cmd.c_str(), "r"); in RunCommand()
278 void HdcClient::RunExecuteCommand(const string& cmd) in RunExecuteCommand() argument
281 RunCommandWin32(cmd); in RunExecuteCommand()
283 RunCommand(cmd); in RunExecuteCommand()
287 bool IsCaptureCommand(const string& cmd) in IsCaptureCommand() argument
290 int length = cmd.length(); in IsCaptureCommand()
293 if (cmd[index] == ' ') { in IsCaptureCommand()
297 if (!strncmp(cmd.c_str() + index, captureOption.c_str(), captureOption.size())) { in IsCaptureCommand()
444 char *cmd = hChannel->bufStd; in ReadStd() local
449 thisClass->Send(hChannel->channelId, reinterpret_cast<uint8_t *>(cmd), strlen(cmd)); in ReadStd()
582 uint16_t cmd = 0; in ReadChannel() local
585 cmd = *reinterpret_cast<uint16_t *>(buf); in ReadChannel()
586 bOffset = IsOffset(cmd); in ReadChannel()
588 if (cmd == CMD_CHECK_SERVER && isCheckVersionCmd) { in ReadChannel()
600 hTaskInfo->masterSlave = (cmd == CMD_FILE_INIT); in ReadChannel()
603 … if (!fileTask->CommandDispatch(cmd, buf + sizeof(uint16_t), bytesIO - sizeof(uint16_t))) { in ReadChannel()
611 hTaskInfo->masterSlave = (cmd == CMD_APP_INIT); in ReadChannel()
614 … if (!appTask->CommandDispatch(cmd, buf + sizeof(uint16_t), bytesIO - sizeof(uint16_t))) { in ReadChannel()
704 bool HdcClient::IsOffset(uint16_t cmd) in IsOffset() argument
706 return (cmd == CMD_CHECK_SERVER) || in IsOffset()
707 (cmd == CMD_FILE_INIT) || in IsOffset()
708 (cmd == CMD_FILE_CHECK) || in IsOffset()
709 (cmd == CMD_FILE_BEGIN) || in IsOffset()
710 (cmd == CMD_FILE_DATA) || in IsOffset()
711 (cmd == CMD_FILE_FINISH) || in IsOffset()
712 (cmd == CMD_FILE_MODE) || in IsOffset()
713 (cmd == CMD_DIR_MODE) || in IsOffset()
714 (cmd == CMD_APP_INIT) || in IsOffset()
715 (cmd == CMD_APP_CHECK) || in IsOffset()
716 (cmd == CMD_APP_BEGIN) || in IsOffset()
717 (cmd == CMD_APP_DATA) || in IsOffset()
718 (cmd == CMD_APP_FINISH); in IsOffset()