提交 7815064b 编写于 作者: L laiguizhong

修改拼写错误

Signed-off-by: Nlaiguizhong <laiguizhong@huawei.com>
上级 916544d7
......@@ -68,9 +68,9 @@ static void CmdOnRecvMessage(const TaskHandle task, const uint8_t *buffer, uint3
BEGET_LOGI("[control_fd] CmdOnRecvMessage %s len %d.", (char *)buffer, buffLen);
}
static void CmdOnConntectComplete(const TaskHandle client)
static void CmdOnConnectComplete(const TaskHandle client)
{
BEGET_LOGI("[control_fd] CmdOnConntectComplete");
BEGET_LOGI("[control_fd] CmdOnConnectComplete");
}
static void CmdOnClose(const TaskHandle task)
......@@ -105,8 +105,8 @@ static CmdAgent *CmdAgentCreate(const char *server)
info.server = (char *)server;
info.baseInfo.userDataSize = sizeof(CmdAgent);
info.baseInfo.close = CmdOnClose;
info.disConntectComplete = CmdDisConnectComplete;
info.connectComplete = CmdOnConntectComplete;
info.disConnectComplete = CmdDisConnectComplete;
info.connectComplete = CmdOnConnectComplete;
info.sendMessageComplete = CmdOnSendMessageComplete;
info.recvMessage = CmdOnRecvMessage;
LE_STATUS status = LE_CreateStreamClient(LE_GetDefaultLoop(), &task, &info);
......
......@@ -100,7 +100,7 @@ static int CmdOnIncommingConntect(const LoopHandle loop, const TaskHandle server
info.baseInfo.flags = TASK_STREAM | TASK_PIPE | TASK_CONNECT;
info.baseInfo.close = OnClose;
info.baseInfo.userDataSize = sizeof(CmdTask);
info.disConntectComplete = NULL;
info.disConnectComplete = NULL;
info.sendMessageComplete = NULL;
info.recvMessage = CmdOnRecvMessage;
int ret = LE_AcceptStreamClient(LE_GetDefaultLoop(), server, &client, &info);
......@@ -127,7 +127,7 @@ void CmdServiceInit(const char *socketPath, CallbackControlFdProcess func)
info.server = (char *)socketPath;
info.socketId = -1;
info.baseInfo.close = NULL;
info.disConntectComplete = NULL;
info.disConnectComplete = NULL;
info.incommingConntect = CmdOnIncommingConntect;
info.sendMessageComplete = NULL;
info.recvMessage = NULL;
......
......@@ -37,7 +37,7 @@ typedef enum {
SERVICE_SUSPENDED,
SERVICE_FREEZED,
SERVICE_DISABLED,
SERVICE_CRITIAL
SERVICE_CRITICAL
} ServiceStatus;
enum ServiceAction {
......
......@@ -102,7 +102,7 @@ typedef struct {
LE_BaseInfo baseInfo;
char *server;
int socketId;
LE_DisConntectComplete disConntectComplete;
LE_DisConntectComplete disConnectComplete;
LE_IncommingConntect incommingConntect;
LE_SendMessageComplete sendMessageComplete;
LE_RecvMessage recvMessage;
......@@ -111,7 +111,7 @@ typedef struct {
typedef struct {
LE_BaseInfo baseInfo;
char *server;
LE_DisConntectComplete disConntectComplete;
LE_DisConntectComplete disConnectComplete;
LE_ConntectComplete connectComplete;
LE_SendMessageComplete sendMessageComplete;
LE_RecvMessage recvMessage;
......
......@@ -93,8 +93,8 @@ static LE_STATUS HandleStreamEvent_(const LoopHandle loopHandle, const TaskHandl
}
if (status == LE_DIS_CONNECTED) {
loop->delEvent(loop, GetSocketFd(handle), Event_Read | Event_Write);
if (stream->disConntectComplete) {
stream->disConntectComplete(handle);
if (stream->disConnectComplete) {
stream->disConnectComplete(handle);
}
LE_CloseStreamTask(loopHandle, handle);
}
......@@ -116,8 +116,8 @@ static LE_STATUS HandleClientEvent_(const LoopHandle loopHandle, const TaskHandl
status = HandleRecvMsg_(loopHandle, handle, client->recvMessage);
}
if (status == LE_DIS_CONNECTED) {
if (client->disConntectComplete) {
client->disConntectComplete(handle);
if (client->disConnectComplete) {
client->disConnectComplete(handle);
}
client->connected = 0;
LE_CloseStreamTask(loopHandle, handle);
......@@ -201,7 +201,7 @@ LE_STATUS LE_CreateStreamClient(const LoopHandle loopHandle,
task->connectComplete = info->connectComplete;
task->sendMessageComplete = info->sendMessageComplete;
task->recvMessage = info->recvMessage;
task->disConntectComplete = info->disConntectComplete;
task->disConnectComplete = info->disConnectComplete;
EventLoop *loop = (EventLoop *)loopHandle;
loop->addEvent(loop, (const BaseTask *)task, Event_Read);
*taskHandle = (TaskHandle)task;
......@@ -225,7 +225,7 @@ LE_STATUS LE_AcceptStreamClient(const LoopHandle loopHandle, const TaskHandle se
return LE_NO_MEMORY, "Failed to create task");
task->stream.base.handleEvent = HandleStreamEvent_;
task->stream.base.innerClose = HandleStreamTaskClose_;
task->disConntectComplete = info->disConntectComplete;
task->disConnectComplete = info->disConnectComplete;
task->sendMessageComplete = info->sendMessageComplete;
task->recvMessage = info->recvMessage;
task->serverTask = (StreamServerTask *)server;
......
......@@ -91,12 +91,12 @@ typedef struct {
StreamServerTask *serverTask;
LE_SendMessageComplete sendMessageComplete;
LE_RecvMessage recvMessage;
LE_DisConntectComplete disConntectComplete;
LE_DisConntectComplete disConnectComplete;
} StreamConnectTask;
typedef struct {
StreamTask stream;
LE_DisConntectComplete disConntectComplete;
LE_DisConntectComplete disConnectComplete;
LE_ConntectComplete connectComplete;
LE_SendMessageComplete sendMessageComplete;
LE_RecvMessage recvMessage;
......
......@@ -69,7 +69,7 @@ int ParamStreamCreate(ParamTaskPtr *stream, ParamTaskPtr server,
info.baseInfo.flags |= TASK_TEST;
}
info.baseInfo.close = streamInfo->close;
info.disConntectComplete = NULL;
info.disConnectComplete = NULL;
info.sendMessageComplete = NULL;
info.recvMessage = OnReceiveRequest;
g_recvMessage = streamInfo->recvMessage;
......
......@@ -545,7 +545,7 @@ const static InitArgInfo g_servieStatusMap[] = {
{"suspended", SERVICE_SUSPENDED},
{"freezed", SERVICE_FREEZED},
{"disabled", SERVICE_DISABLED},
{"critial", SERVICE_CRITIAL}
{"critical", SERVICE_CRITICAL}
};
const InitArgInfo *GetServieStatusMap(int *size)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册