33#ifndef MYSQL_BINLOG_EVENT_WRAPPER_FUNCTIONS_H
34#define MYSQL_BINLOG_EVENT_WRAPPER_FUNCTIONS_H
36#ifndef STANDALONE_BINLOG
61#define BAPI_ASSERT(x) assert(x)
62#define BAPI_PRINT(name, params) DBUG_PRINT(name, params)
63#define BAPI_ENTER(x) DBUG_ENTER(x)
64#define BAPI_RETURN(x) DBUG_RETURN(x)
65#define BAPI_TRACE DBUG_TRACE
66#define BAPI_VOID_RETURN DBUG_VOID_RETURN
67#define BAPI_LOG(x, y) DBUG_LOG(x, y)
68#define BAPI_VAR(v) DBUG_VAR(v)
70#define BAPI_ASSERT(x) assert(x)
71#define BAPI_PRINT(name, params) \
74#define BAPI_ENTER(x) \
77#define BAPI_RETURN(x) return (x)
81#define BAPI_VOID_RETURN return
82#define BAPI_LOG(x, y) \
88#define BAPI_ASSERT(x) \
91#define BAPI_PRINT(name, params) \
94#define BAPI_ENTER(x) \
97#define BAPI_RETURN(x) return (x)
101#define BAPI_VOID_RETURN return
102#define BAPI_LOG(x, y) \
105#define BAPI_VAR(v) ""
125 size_t len = strlen(s);
127 if (
n < len) len =
n;
130 if (!
result)
return nullptr;
133 return (
char *)memcpy(
result, s, len);
176 if (dest) memcpy(dest,
source, len);
194 void *dest =
nullptr;
#define MY_WME
Definition: my_sys.h:130
unsigned int PSI_memory_key
Instrumented memory key.
Definition: psi_memory_bits.h:49
static int flags[50]
Definition: hp_test1.cc:40
#define malloc(A)
Definition: lexyy.cc:914
#define free(A)
Definition: lexyy.cc:915
#define MYF(v)
Definition: my_inttypes.h:97
void * my_malloc(PSI_memory_key key, size_t size, int flags)
Allocates size bytes of memory.
Definition: my_memory.cc:57
void my_free(void *ptr)
Frees the memory pointed by the ptr.
Definition: my_memory.cc:81
Common header for many mysys elements.
The namespace contains classes representing events that can occur in a replication stream.
Definition: binlog_event.cpp:38
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:123
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:169
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:213
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:193
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:150
size_t size(const char *const c)
Definition: base64.h:46
struct result result
Definition: result.h:34
repeated Source source
Definition: replication_asynchronous_connection_failover.proto:42
void * my_memdup(PSI_memory_key key, const void *from, size_t length, myf_t flags)
Definition: my_malloc.cc:540
char * my_strndup(PSI_memory_key key, const char *from, size_t length, myf_t flags)
Definition: my_malloc.cc:556
PSI_memory_key key_memory_log_event
Definition: log_event.cc:192
int n
Definition: xcom_base.cc:509