* @brief Destroy and free a file descriptor structure * * @param[in] file Pointer to the file descriptor structure to be destroyed */
| 273 | * @param[in] file Pointer to the file descriptor structure to be destroyed |
| 274 | */ |
| 275 | void dfs_file_destroy(struct dfs_file *file) |
| 276 | { |
| 277 | rt_mutex_detach(&file->pos_lock); |
| 278 | |
| 279 | if (file->mmap_context) |
| 280 | { |
| 281 | rt_free(file->mmap_context); |
| 282 | } |
| 283 | |
| 284 | rt_free(file); |
| 285 | } |
| 286 | |
| 287 | /** |
| 288 | * @ingroup group_fs_file_descriptor |
no test coverage detected