Merge pull request #25 from Livox-SDK/draft_pr

fix:fix protocol parse bug
This commit is contained in:
livox
2020-04-29 12:11:04 +08:00
committed by GitHub
2 changed files with 2 additions and 2 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 115 KiB

View File

@@ -131,8 +131,8 @@ int32_t CommProtocol::ParseCommStream(CommPacket *o_pack) {
default: { FsmParserStateTransfer(kSearchPacketPreamble); }
}
if (ret == kParseNeedMoreData)
break; /* */
/* Must exit when in the below case */
if ((ret == kParseSuccess) || (ret == kParseNeedMoreData)) break;
}
return ret;