INGOR
Loading...
Searching...
No Matches
Functions | Variables
ytLib

Functions

void ytLib_init ()
 Initializes the YT Lib library.
 
const char * ytLib_version ()
 Returns the ytLib Git version.
 
void ytLib_showMemoryTable (FILE *fp)
 Prints the ytLib memory table.
 
size_t ytLib_getAllocMemory ()
 Returns the total size of allocated memory.
 
void ytLib_malloc (size_t size, int code, int location)
 Allocates memory.
 

Variables

FILE * ytLib_ERR
 File pointer for error output.
 

Detailed Description

Function Documentation

◆ ytLib_getAllocMemory()

size_t ytLib_getAllocMemory ( )

Returns the total size of allocated memory.

To use this, set ENABLE_MEMCHECK=1 when compiling the binary.

◆ ytLib_malloc()

void ytLib_malloc ( size_t  size,
int  code,
int  location 
)

Allocates memory.

Parameters
sizebyte size to allocate
codeError code if failed to allocate.
locationError location code. If 0, ingored.
Returns
pointer to the allocated memory.

◆ ytLib_showMemoryTable()

void ytLib_showMemoryTable ( FILE *  fp)

Prints the ytLib memory table.

To use this, set ENABLE_MEMCHECK=1 when compling the binary.

Variable Documentation

◆ ytLib_ERR

FILE* ytLib_ERR
extern

File pointer for error output.

This variable is used for the message output by all the YT Lib routines. This is initialized to stderr in ytLib_init().