Commit a5dd9123 authored by chen.weican's avatar chen.weican

【修改内容】去掉不必要的打印

【提交人】陈伟灿
parent 12530ad9
...@@ -2885,7 +2885,7 @@ static int MQTTAsync_cleanSession(Clients* client) ...@@ -2885,7 +2885,7 @@ static int MQTTAsync_cleanSession(Clients* client)
static int MQTTAsync_deliverMessage(MQTTAsyncs* m, char* topicName, size_t topicLen, MQTTAsync_message* mm) static int MQTTAsync_deliverMessage(MQTTAsyncs* m, char* topicName, size_t topicLen, MQTTAsync_message* mm)
{ {
int rc; int rc;
printf("[%s][%d]\n",__FUNCTION__,__LINE__);
Log(TRACE_MIN, -1, "Calling messageArrived for client %s, queue depth %d", Log(TRACE_MIN, -1, "Calling messageArrived for client %s, queue depth %d",
m->c->clientID, m->c->messageQueue->count); m->c->clientID, m->c->messageQueue->count);
rc = (*(m->ma))(m->maContext, topicName, (int)topicLen, mm); rc = (*(m->ma))(m->maContext, topicName, (int)topicLen, mm);
...@@ -2902,7 +2902,6 @@ void Protocol_processPublication(Publish* publish, Clients* client, int allocate ...@@ -2902,7 +2902,6 @@ void Protocol_processPublication(Publish* publish, Clients* client, int allocate
MQTTAsync_message* mm = NULL; MQTTAsync_message* mm = NULL;
MQTTAsync_message initialized = MQTTAsync_message_initializer; MQTTAsync_message initialized = MQTTAsync_message_initializer;
int rc = 0; int rc = 0;
printf("[%s][%d]\n",__FUNCTION__,__LINE__);
FUNC_ENTRY; FUNC_ENTRY;
if ((mm = malloc(sizeof(MQTTAsync_message))) == NULL) if ((mm = malloc(sizeof(MQTTAsync_message))) == NULL)
......
...@@ -304,7 +304,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock) ...@@ -304,7 +304,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock)
Clients* client = NULL; Clients* client = NULL;
char* clientid = NULL; char* clientid = NULL;
int rc = TCPSOCKET_COMPLETE; int rc = TCPSOCKET_COMPLETE;
printf("[%s][%d]\n",__FUNCTION__,__LINE__);
FUNC_ENTRY; FUNC_ENTRY;
client = (Clients*)(ListFindItem(bstate->clients, &sock, clientSocketCompare)->content); client = (Clients*)(ListFindItem(bstate->clients, &sock, clientSocketCompare)->content);
...@@ -313,7 +312,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock) ...@@ -313,7 +312,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock)
publish->header.bits.retain, publish->payloadlen, min(20, publish->payloadlen), publish->payload); publish->header.bits.retain, publish->payloadlen, min(20, publish->payloadlen), publish->payload);
if (publish->header.bits.qos == 0){ if (publish->header.bits.qos == 0){
printf("[%s][%d]\n",__FUNCTION__,__LINE__);
Protocol_processPublication(publish, client, 1); Protocol_processPublication(publish, client, 1);
} }
else if (!Socket_noPendingWrites(sock)) else if (!Socket_noPendingWrites(sock))
...@@ -324,7 +322,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock) ...@@ -324,7 +322,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock)
rc = MQTTPacket_send_puback(publish->MQTTVersion, publish->msgId, &client->net, client->clientID); rc = MQTTPacket_send_puback(publish->MQTTVersion, publish->msgId, &client->net, client->clientID);
/* if we get a socket error from sending the puback, should we ignore the publication? */ /* if we get a socket error from sending the puback, should we ignore the publication? */
Protocol_processPublication(publish, client, 1); Protocol_processPublication(publish, client, 1);
printf("[%s][%d]\n",__FUNCTION__,__LINE__);
} }
else if (publish->header.bits.qos == 2) else if (publish->header.bits.qos == 2)
{ {
...@@ -374,7 +371,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock) ...@@ -374,7 +371,6 @@ int MQTTProtocol_handlePublishes(void* pack, int sock)
publish1.payloadlen = m->publish->payloadlen; publish1.payloadlen = m->publish->payloadlen;
publish1.MQTTVersion = m->MQTTVersion; publish1.MQTTVersion = m->MQTTVersion;
publish1.properties = m->properties; publish1.properties = m->properties;
printf("[%s][%d]\n",__FUNCTION__,__LINE__);
Protocol_processPublication(&publish1, client, 1); Protocol_processPublication(&publish1, client, 1);
ListRemove(&(state.publications), m->publish); ListRemove(&(state.publications), m->publish);
......
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