Fix extPanId size in NCP scan result packet (#163)

* Fix extPanId size in NCP scan result packet

wpantund scan result handler expects extPanId size to be 0 or 8. If not
- it stops scan result handling. Because mExtPanId is a pointer, it's
size is architecture dependent, and scanning (by chance) works only on
64bit machines. extPanId size should be (is) a constant.

* ncp: Use extPanId size from Thread API headers

OT_EXT_PAN_ID_SIZE is defined in Thread API headers. This removes
dependecy from Thread source files.
This commit is contained in:
Giedrius
2016-06-17 08:50:34 -07:00
committed by Jonathan Hui
parent db85fd2e4b
commit 21ca8d808e
+1 -1
View File
@@ -342,7 +342,7 @@ void NcpBase::HandleActiveScanResult(otActiveScanResult *result)
SPINEL_PROTOCOL_TYPE_THREAD,
flags,
result->mNetworkName,
result->mExtPanId, sizeof(result->mExtPanId)
result->mExtPanId, OT_EXT_PAN_ID_SIZE
);
}
else