mirror of
https://github.com/espressif/openthread.git
synced 2026-09-13 12:40:05 +00:00
[ncp] decode PROP_IPV6_ML_PREFIX property as [6C] (#2625)
This commit is contained in:
@@ -1032,11 +1032,11 @@ otError NcpBase::SetPropertyHandler_IPV6_ML_PREFIX(void)
|
|||||||
{
|
{
|
||||||
otError error = OT_ERROR_NONE;
|
otError error = OT_ERROR_NONE;
|
||||||
const uint8_t *meshLocalPrefix;
|
const uint8_t *meshLocalPrefix;
|
||||||
uint16_t prefixLength;
|
uint8_t prefixLength;
|
||||||
|
|
||||||
SuccessOrExit(error = mDecoder.ReadData(meshLocalPrefix, prefixLength));
|
SuccessOrExit(error = mDecoder.ReadIp6Address(meshLocalPrefix));
|
||||||
|
SuccessOrExit(error = mDecoder.ReadUint8(prefixLength));
|
||||||
VerifyOrExit(prefixLength >= 8, error = OT_ERROR_PARSE);
|
VerifyOrExit(prefixLength == 64, error = OT_ERROR_INVALID_ARGS);
|
||||||
|
|
||||||
error = otThreadSetMeshLocalPrefix(mInstance, meshLocalPrefix);
|
error = otThreadSetMeshLocalPrefix(mInstance, meshLocalPrefix);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user