[utils] remove strnlen (#4483)

This commit is contained in:
Jonathan Hui
2020-01-16 15:46:42 -08:00
parent 708c250fe5
commit 71a7e47c81
22 changed files with 78 additions and 195 deletions
+1 -1
View File
@@ -3611,7 +3611,7 @@ void Interpreter::ProcessLine(char *aBuf, uint16_t aBufLength, Server &aServer)
mServer = &aServer;
VerifyOrExit(aBuf != NULL && strnlen(aBuf, aBufLength + 1) <= aBufLength);
VerifyOrExit(aBuf != NULL && StringLength(aBuf, aBufLength + 1) <= aBufLength);
VerifyOrExit(Utils::CmdLineParser::ParseCmd(aBuf, argc, argv, kMaxArgs) == OT_ERROR_NONE,
mServer->OutputFormat("Error: too many args (max %d)\r\n", kMaxArgs));