Basic functions for the whole project.
More...
#include <stdbool.h>
Go to the source code of this file.
|
#define | _BOLD_RED "\033[1m\033[31m" |
|
#define | _RESET_COLOR "\033[0m" |
|
#define | _ERROR_SIG _BOLD_RED "ERROR => " _RESET_COLOR |
|
#define | _SUCCESS true |
|
#define | _FAILED false |
|
#define | _NOT_FOUND -1 |
|
Basic functions for the whole project.
◆ is_file_exist()
bool is_file_exist |
( |
const char * |
fname | ) |
|
Check If file exists or not.
- Parameters
-
- Returns
- If exists, return true. If not, return false.
◆ is_null_ptr()
bool is_null_ptr |
( |
const void * |
ptr, |
|
|
const char * |
func_name |
|
) |
| |
Check if the pointer is a null pointer.
- Parameters
-
ptr | the pointer to check is null or not. |
func_name | Use func to identify which function found a null pointer. |
- Returns
- If is null pointer, return true. If not, return false.