diff --git a/api/i_cmdparser.hpp b/api/i_cmdparser.hpp index 54c3b47..d09ac90 100644 --- a/api/i_cmdparser.hpp +++ b/api/i_cmdparser.hpp @@ -42,7 +42,7 @@ class ICmdParserACK { } int32_t *getAck(int index) { - if (index < 0 || index >= sizeof(rawdata) / 4) { + if (index < 0 || index >= (int32_t)(sizeof(rawdata) / 4)) { return nullptr; } return (int32_t *)rawdata + index; @@ -64,4 +64,4 @@ class ICmdParser { virtual void regCMD(const char *cmdname, const char *helpinfo, int paraNum, ICmdFunction_t cmdimpl) = 0; }; -} // namespace iflytop \ No newline at end of file +} // namespace iflytop