32#ifndef MYSQL_BINLOG_EVENT_WRAPPER_FUNCTIONS_H
33#define MYSQL_BINLOG_EVENT_WRAPPER_FUNCTIONS_H
35#ifndef STANDALONE_BINLOG
60#define BAPI_ASSERT(x) assert(x)
61#define BAPI_PRINT(name, params) DBUG_PRINT(name, params)
62#define BAPI_ENTER(x) DBUG_ENTER(x)
63#define BAPI_RETURN(x) DBUG_RETURN(x)
64#define BAPI_TRACE DBUG_TRACE
65#define BAPI_VOID_RETURN DBUG_VOID_RETURN
66#define BAPI_LOG(x, y) DBUG_LOG(x, y)
67#define BAPI_VAR(v) DBUG_VAR(v)
69#define BAPI_ASSERT(x) assert(x)
70#define BAPI_PRINT(name, params) \
73#define BAPI_ENTER(x) \
76#define BAPI_RETURN(x) return (x)
80#define BAPI_VOID_RETURN return
81#define BAPI_LOG(x, y) \
87#define BAPI_ASSERT(x) \
90#define BAPI_PRINT(name, params) \
93#define BAPI_ENTER(x) \
96#define BAPI_RETURN(x) return (x)
100#define BAPI_VOID_RETURN return
101#define BAPI_LOG(x, y) \
104#define BAPI_VAR(v) ""
124 size_t len = strlen(s);
126 if (
n < len) len =
n;
129 if (!
result)
return nullptr;
132 return (
char *)memcpy(
result, s, len);
175 if (dest) memcpy(dest,
source, len);
193 void *dest =
nullptr;
#define MY_WME
Definition: my_sys.h:127
unsigned int PSI_memory_key
Instrumented memory key.
Definition: psi_memory_bits.h:48
static int flags[50]
Definition: hp_test1.cc:39
#define malloc(A)
Definition: lexyy.cc:914
#define free(A)
Definition: lexyy.cc:915
#define MYF(v)
Definition: my_inttypes.h:96
void * my_malloc(PSI_memory_key key, size_t size, int flags)
Allocates size bytes of memory.
Definition: my_memory.cc:56
void my_free(void *ptr)
Frees the memory pointed by the ptr.
Definition: my_memory.cc:80
Common header for many mysys elements.
The namespace contains classes representing events that can occur in a replication stream.
Definition: binlog_event.cpp:35
char * strndup(const char *s, size_t n)
The strndup() function returns a pointer to a new string which is a duplicate of the string s,...
Definition: wrapper_functions.h:122
void * bapi_memdup(const void *source, size_t len)
This is a wrapper function, and returns a pointer to a new memory with the contents copied from the i...
Definition: wrapper_functions.h:168
void bapi_free(void *ptr)
This is a wrapper function in order to free the memory allocated from the heap in the binlogevent lib...
Definition: wrapper_functions.h:212
void * bapi_malloc(size_t size, int flags)
This is a wrapper function in order to allocate memory from the heap in the binlogevent library.
Definition: wrapper_functions.h:192
const char * bapi_strndup(const char *destination, size_t n)
This is a wrapper function, and returns a pointer to a new string which is a duplicate of the input s...
Definition: wrapper_functions.h:149
struct result result
Definition: result.h:33
repeated Source source
Definition: replication_asynchronous_connection_failover.proto:41
void * my_memdup(PSI_memory_key key, const void *from, size_t length, myf_t flags)
Definition: my_malloc.cc:539
char * my_strndup(PSI_memory_key key, const char *from, size_t length, myf_t flags)
Definition: my_malloc.cc:555
PSI_memory_key key_memory_log_event
Definition: log_event.cc:188
int n
Definition: xcom_base.cc:508