created doc for why2_strdup

This commit is contained in:
Václav Šmejkal 2025-01-25 21:02:12 +01:00
parent bf0355761b
commit 260c998782
Signed by: ENGO150
GPG Key ID: 4A57E86482968843
2 changed files with 38 additions and 0 deletions

View File

@ -0,0 +1,37 @@
<!--
This is part of WHY2
Copyright (C) 2022 Václav Šmejkal
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
-->
# why2_strdup
## Parameters
| Identifier | Data type |
| ---------- | --------- |
| `string` | `char *` |
## Attributes
| | |
| ------------------ | ---------------------------------------------- |
| **Return type** | `void *` |
| **Header comment** | *This functions doesn't have any description.* |
| **Added in commit** | [`d5ae68c621b61823dc18cf7fe2d93dfb036cbbc1`](https://github.com/ENGO150/WHY2/commit/d5ae68c621b61823dc18cf7fe2d93dfb036cbbc1) |
## Description
Function passes `string` into [`strdup`](https://linux.die.net/man/3/strdup) function and returns the output value. The value is also pushed to [`linked-list`](../../../../types/core/llist/why2_list_t) for garbage collector.

View File

@ -93,6 +93,7 @@ You can find documentation for every *public* function of WHY2 below.
| [`why2_calloc`](./core/memory/why2_calloc) | *This functions doesn't have any description.* |
| [`why2_realloc`](./core/memory/why2_realloc) | This doesn't preserve content of pointer! |
| [`why2_recalloc`](./core/memory/why2_recalloc) | Same as why2_realloc but fills the pointer with null-terms |
| [`why2_strdup`](./core/memory/why2_strdup) | *This functions doesn't have any description.* |
## Logger