mirror of
https://github.com/lifegpc/c-utils.git
synced 2026-07-08 01:30:39 +08:00
Initialize
This commit is contained in:
16
cstr_util.h
Normal file
16
cstr_util.h
Normal file
@@ -0,0 +1,16 @@
|
||||
#ifndef _UTILS_CSTR_UTIL_H
|
||||
#define _UTILS_CSTR_UTIL_H
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
/**
|
||||
* @brief Copy string to another string
|
||||
* @param dest The pointer of output string
|
||||
* @param str The input string
|
||||
* @return 0 if successed. `1` - args contains NULL. `2` - Out of memory.
|
||||
*/
|
||||
int cstr_util_copy_str(char** dest, const char* str);
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
Reference in New Issue
Block a user