51 #ifdef COMPILE_MEMORY_PROFILE
53 #if defined(COMPILE_ON_WINDOWS) || defined(COMPILE_ON_MINGW)
54 #error "This stuff should be never compiled on Windows"
84 #ifdef COMPILE_MEMORY_CHECKS
86 #ifdef COMPILE_ON_WINDOWS
87 #error "This stuff should be never compiled on Windows"
97 void * ptr = ::malloc(size);
103 inline void *
reallocate(
void * ptr,
int size)
105 ptr = ::realloc(ptr, size);
115 return ::malloc(size);
120 return ::realloc(ptr, size);
139 inline void move(
void * dst_ptr,
const void * src_ptr,
int len)
141 memmove(dst_ptr, src_ptr, len);
152 inline void set(
void * dst_ptr,
char c,
int len)
154 memset(dst_ptr, c, len);
166 inline void copy(
void * dst_ptr,
const void * src_ptr,
int len)
168 memcpy(dst_ptr, src_ptr, len);
173 #endif //_KVI_MALLOC_H_
char s char s char s s s s s char char c s *s c s s s d c s *s d c d d d d c
Definition: KviIrcNumericCodes.h:391
void * reallocate(void *ptr, int size)
Definition: KviMemory.h:118
void * allocate(int size)
COMPILE_MEMORY_PROFILE.
Definition: KviMemory.h:113
void set(void *dst_ptr, char c, int len)
Initializes len bytes of memory starting from dst_ptr to c.
Definition: KviMemory.h:152
This file contains compile time settings.
void copy(void *dst_ptr, const void *src_ptr, int len)
Moves len bytes from src_ptr to dst_ptr.
Definition: KviMemory.h:166
void free(void *ptr)
COMPILE_MEMORY_CHECKS.
Definition: KviMemory.h:125
void move(void *dst_ptr, const void *src_ptr, int len)
COMPILE_MEMORY_PROFILE.
Definition: KviMemory.h:139
#define KVILIB_API
Definition: kvi_settings.h:125