Compile modutil.c as C++
This commit is contained in:
parent
44fe995574
commit
640f0d5139
@ -326,9 +326,9 @@ extern GWBUF *gwbuf_split(GWBUF **buf, size_t length);
|
||||
* Set given type to all buffers on the list.
|
||||
* *
|
||||
* @param buf The shared buffer
|
||||
* @param type Type to be added
|
||||
* @param type Type to be added, mask of @c gwbuf_type_t values.
|
||||
*/
|
||||
extern void gwbuf_set_type(GWBUF *head, gwbuf_type_t type);
|
||||
extern void gwbuf_set_type(GWBUF *head, uint32_t type);
|
||||
|
||||
/**
|
||||
* Add a property to a buffer.
|
||||
|
@ -18,7 +18,8 @@ add_library(maxscale-common SHARED
|
||||
maxscale_pcre2.cc
|
||||
misc.cc
|
||||
mlist.cc
|
||||
modutil.c monitor.c queuemanager.c query_classifier.cc poll.c random_jkiss.c resultset.c router.cc secrets.c server.c service.c session.c spinlock.c thread.c users.c utils.c skygw_utils.cc statistics.c listener.c ssl.c mysql_utils.c mysql_binlog.c modulecmd.c)
|
||||
modutil.cc
|
||||
monitor.c queuemanager.c query_classifier.cc poll.c random_jkiss.c resultset.c router.cc secrets.c server.c service.c session.c spinlock.c thread.c users.c utils.c skygw_utils.cc statistics.c listener.c ssl.c mysql_utils.c mysql_binlog.c modulecmd.c)
|
||||
|
||||
if(WITH_JEMALLOC)
|
||||
target_link_libraries(maxscale-common ${JEMALLOC_LIBRARIES})
|
||||
|
@ -643,7 +643,7 @@ gwbuf_rtrim(GWBUF *head, unsigned int n_bytes)
|
||||
return rval;
|
||||
}
|
||||
|
||||
void gwbuf_set_type(GWBUF* buf, gwbuf_type_t type)
|
||||
void gwbuf_set_type(GWBUF* buf, uint32_t type)
|
||||
{
|
||||
/** Set type consistenly to all buffers on the list */
|
||||
while (buf != NULL)
|
||||
|
@ -46,11 +46,11 @@ static const char* sub_single = "$1.";
|
||||
static const char* sub_escape = "\\.";
|
||||
|
||||
static void modutil_reply_routing_error(
|
||||
DCB* backend_dcb,
|
||||
int error,
|
||||
char* state,
|
||||
char* errstr,
|
||||
uint32_t flags);
|
||||
DCB* backend_dcb,
|
||||
int error,
|
||||
const char* state,
|
||||
char* errstr,
|
||||
uint32_t flags);
|
||||
|
||||
|
||||
/**
|
||||
@ -329,7 +329,7 @@ modutil_get_query(GWBUF *buf)
|
||||
char* query_str = NULL;
|
||||
|
||||
packet = GWBUF_DATA(buf);
|
||||
packet_type = packet[4];
|
||||
packet_type = (mysql_server_cmd_t)packet[4];
|
||||
|
||||
switch (packet_type)
|
||||
{
|
||||
@ -758,11 +758,11 @@ void modutil_reply_auth_error(DCB* backend_dcb,
|
||||
* @param errstr Plain-text string error
|
||||
* @param flags GWBUF type flags
|
||||
*/
|
||||
static void modutil_reply_routing_error(DCB* backend_dcb,
|
||||
int error,
|
||||
char* state,
|
||||
char* errstr,
|
||||
uint32_t flags)
|
||||
static void modutil_reply_routing_error(DCB* backend_dcb,
|
||||
int error,
|
||||
const char* state,
|
||||
char* errstr,
|
||||
uint32_t flags)
|
||||
{
|
||||
GWBUF* buf;
|
||||
CHK_DCB(backend_dcb);
|
Loading…
x
Reference in New Issue
Block a user