MySQL 8.3.0
Source Code Documentation
my_memory.h File Reference

Go to the source code of this file.

Macros

#define MY_ZEROFILL   32 /** fill array with zero */
 Below functions are used by the components. More...
 

Functions

void * my_malloc (PSI_memory_key key, size_t size, int flags)
 Allocates size bytes of memory. More...
 
void my_free (void *ptr)
 Frees the memory pointed by the ptr. More...
 

Macro Definition Documentation

◆ MY_ZEROFILL

#define MY_ZEROFILL   32 /** fill array with zero */

Below functions are used by the components.

And these functions will be in a static library(liblibrary_mysys.a) and the library is statically linked whenever any component needs these function.

Function Documentation

◆ my_free()

void my_free ( void *  ptr)

Frees the memory pointed by the ptr.

Parameters
ptrmemory address to be freed

◆ my_malloc()

void * my_malloc ( PSI_memory_key  key,
size_t  size,
int  flags 
)

Allocates size bytes of memory.

Parameters
keyP_S key used for memory instrumentation
sizesize bytes to allocate the memory
flagsused at the time of allocation. Could be MY_ZEROFILL