提交 fc8e0d4a 编写于 作者: I Ian Craggs

Merge branch 'chenzhenhua5-develop' into develop

...@@ -2080,12 +2080,19 @@ MQTTResponse MQTTClient_subscribeMany5(MQTTClient handle, int count, char* const ...@@ -2080,12 +2080,19 @@ MQTTResponse MQTTClient_subscribeMany5(MQTTClient handle, int count, char* const
} }
else else
{ {
ListElement* current = NULL; ListElement *current = NULL;
i = 0;
while (ListNextElement(sub->qoss, &current)) /* if the returned count is greater than requested, it's an error*/
if (sub->qoss->count > count)
rc = MQTTCLIENT_FAILURE;
else
{ {
int* reqqos = (int*)(current->content); i = 0;
qos[i++] = *reqqos; while (ListNextElement(sub->qoss, &current))
{
int *reqqos = (int*) (current->content);
qos[i++] = *reqqos;
}
} }
resp.reasonCode = rc; resp.reasonCode = rc;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册