MXS-1249: Qc, the server version is passed as a single integer
To be compatible with how the version is managed elsewhere.
This commit is contained in:
@ -99,9 +99,7 @@ static thread_local struct
|
||||
// The version information is not used; the embedded library parses according
|
||||
// to the version of the embedded library it has been linked with. However, we
|
||||
// need to store the information so that qc_[get|set]_server_version will work.
|
||||
uint32_t version_major;
|
||||
uint32_t version_minor;
|
||||
uint32_t version_patch;
|
||||
uint64_t version;
|
||||
} this_thread;
|
||||
|
||||
#define QTYPE_LESS_RESTRICTIVE_THAN_WRITE(t) (t<QUERY_TYPE_WRITE ? true : false)
|
||||
@ -2600,18 +2598,14 @@ int32_t qc_mysql_get_function_info(GWBUF* buf,
|
||||
return QC_RESULT_OK;
|
||||
}
|
||||
|
||||
void qc_mysql_set_server_version(uint32_t major, uint32_t minor, uint32_t patch)
|
||||
void qc_mysql_set_server_version(uint64_t version)
|
||||
{
|
||||
this_thread.version_major = major;
|
||||
this_thread.version_minor = minor;
|
||||
this_thread.version_patch = patch;
|
||||
this_thread.version = version;
|
||||
}
|
||||
|
||||
void qc_mysql_get_server_version(uint32_t* major, uint32_t* minor, uint32_t* patch)
|
||||
void qc_mysql_get_server_version(uint64_t* version)
|
||||
{
|
||||
*major = this_thread.version_major;
|
||||
*minor = this_thread.version_minor;
|
||||
*patch = this_thread.version_patch;
|
||||
*version = this_thread.version;
|
||||
}
|
||||
|
||||
namespace
|
||||
|
Reference in New Issue
Block a user