Fix of warning: may be used uninitialized in this function

Signed-off-by: tomoaki <tomoaki@tomy-tech.com>
This commit is contained in:
tomoaki
2017-09-28 07:59:46 +09:00
parent 4935d2aa86
commit 6905e7aa1c

View File

@@ -500,6 +500,7 @@ char* MQTTGWPacket::getMsgId(char* pbuf)
{
case PUBLISH:
Publish pub;
pub.msgId = 0;
getPUBLISH(&pub);
if ( _header.bits.dup )
{