[joiner] remove static requirement for vendor parameters in Start() (#3748)

This commit updates the `Joiner` class implementation to remove the
requirement for `Start()` vendor related parameters (vendor name,
model, sw version, data) to be static (string). This is done without
requiring the `Joiner` class to use member variables to store/copy
the strings by preparing the "Joiner Finalize" message early on (note
that these parameters are included in this message) and keeping track
of the dynamically allocated `Coap::Message` pointer instead.
This commit is contained in:
Abtin Keshavarzian
2019-04-11 10:11:59 -07:00
committed by Jonathan Hui
parent eab62dd699
commit b1ac8a4f19
3 changed files with 78 additions and 52 deletions
+4 -4
View File
@@ -84,10 +84,10 @@ typedef void(OTCALL *otJoinerCallback)(otError aError, void *aContext);
* @param[in] aInstance A pointer to an OpenThread instance.
* @param[in] aPSKd A pointer to the PSKd.
* @param[in] aProvisioningUrl A pointer to the Provisioning URL (may be NULL).
* @param[in] aVendorName A pointer to the Vendor Name (must be static).
* @param[in] aVendorModel A pointer to the Vendor Model (must be static).
* @param[in] aVendorSwVersion A pointer to the Vendor SW Version (must be static).
* @param[in] aVendorData A pointer to the Vendor Data (must be static).
* @param[in] aVendorName A pointer to the Vendor Name (may be NULL).
* @param[in] aVendorModel A pointer to the Vendor Model (may be NULL).
* @param[in] aVendorSwVersion A pointer to the Vendor SW Version (may be NULL).
* @param[in] aVendorData A pointer to the Vendor Data (may be NULL).
* @param[in] aCallback A pointer to a function that is called when the join operation completes.
* @param[in] aContext A pointer to application-specific context.
*