---
title: HTL_thread_attr_destroy
description: "销毁线程属性。"
url: https://www.hikunpeng.com/document/detail/zh/kunpengboostkithistory/2300/accel/kunpengaccel_ksl_16_0107.html
sourcePath: /source/zh/kunpengboostkithistory/2300/accel/kunpengaccel_ksl_16_0107.html
indexId: fa2d93b643aaf77eaa45bc23d98734cfa61a957c66f24a8755064c3d4a07669d74
---
# HTL_thread_attr_destroy

销毁线程属性。

#### 接口定义

int HTL_thread_attr_destroy(HTL_thread_attr_t *thread_attr);


#### 描述

HTL_thread_attr_destroy()销毁线程属性thread_attr的资源，并将thread_attr设置为HTL_THREAD_ATTR_NULL。


#### 参数

| 参数名 | 类型 | 描述 | 输入/输出 |
| --- | --- | --- | --- |
| thread\_attr | HTL\_thread\_attr\_t \* | 线程属性句柄的地址。 | 输入/输出 |


#### 返回值

- HTL_THREAD_SUCCESS：成功。
- 其他：失败。见错误码定义。


#### 示例

```
/* Free the attribute */
ret = HTL_thread_attr_destroy(&attr);
```
