mirror of
https://github.com/sipeed/MaixCDK.git
synced 2026-09-19 14:30:55 -05:00
fix pelling error to "auto_delete"
This commit is contained in:
@@ -24,17 +24,17 @@ namespace maix
|
|||||||
* Construct a Bytes object from a uint8_t array.
|
* Construct a Bytes object from a uint8_t array.
|
||||||
* @param data uint8_t array
|
* @param data uint8_t array
|
||||||
* @param len length of the array
|
* @param len length of the array
|
||||||
* @param auto_detele if true, will delete data when destruct. When copy is true, this arg will be ignore.
|
* @param auto_delete if true, will delete data when destruct. When copy is true, this arg will be ignore.
|
||||||
* @param copy data will be copy to new buffer if true, if false, will use data directly,
|
* @param copy data will be copy to new buffer if true, if false, will use data directly,
|
||||||
* default true to ensure memory safety.
|
* default true to ensure memory safety.
|
||||||
* @maixcdk maix.Bytes.Bytes
|
* @maixcdk maix.Bytes.Bytes
|
||||||
*/
|
*/
|
||||||
Bytes(uint8_t *data, uint32_t len, bool auto_detele = false, bool copy = true)
|
Bytes(uint8_t *data, uint32_t len, bool auto_delete = false, bool copy = true)
|
||||||
{
|
{
|
||||||
this->data = data;
|
this->data = data;
|
||||||
this->data_len = len;
|
this->data_len = len;
|
||||||
this->buff_len = len;
|
this->buff_len = len;
|
||||||
this->_is_alloc = auto_detele;
|
this->_is_alloc = auto_delete;
|
||||||
if(len > 0)
|
if(len > 0)
|
||||||
{
|
{
|
||||||
if(data && copy)
|
if(data && copy)
|
||||||
|
|||||||
Reference in New Issue
Block a user