Commit 14d98d1f authored by 马伊齐's avatar 马伊齐

格式

parent 5ee685a7
...@@ -35,7 +35,7 @@ const char *msg_channel_paths[MSG_CHAN_MAX] = { ...@@ -35,7 +35,7 @@ const char *msg_channel_paths[MSG_CHAN_MAX] = {
/** /**
* @brief 通道发送接收初始化 * @brief 通道发送接收初始化
* *
*/ */
void init_msg_channel(); void init_msg_channel();
...@@ -388,7 +388,7 @@ void init_msg_channel() ...@@ -388,7 +388,7 @@ void init_msg_channel()
int msg_recv(int channel, msg_data_t *msg) int msg_recv(int channel, msg_data_t *msg)
{ {
if (is_initialized == 0 ) if (is_initialized == 0)
{ {
is_initialized = 1; is_initialized = 1;
init_msg_channel(); init_msg_channel();
...@@ -413,12 +413,12 @@ int msg_recv(int channel, msg_data_t *msg) ...@@ -413,12 +413,12 @@ int msg_recv(int channel, msg_data_t *msg)
int msg_send(int channel, uint16_t type, uint32_t code, void *pad, int len) int msg_send(int channel, uint16_t type, uint32_t code, void *pad, int len)
{ {
if (is_initialized == 0 ) if (is_initialized == 0)
{ {
is_initialized = 1; is_initialized = 1;
init_msg_channel(); init_msg_channel();
} }
if (channel < 0 || channel >= MSG_CHAN_MAX || (len > 0 && pad == NULL)) if (channel < 0 || channel >= MSG_CHAN_MAX || (len > 0 && pad == NULL))
{ {
return -1; return -1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment