MXS-1842 Compile all authenticators as C++

Minimal changes, only what is needed to compile.
This commit is contained in:
Johan Wikman
2018-05-02 15:41:03 +03:00
parent aa1c956aa7
commit eba6c0c596
23 changed files with 68 additions and 31 deletions

View File

@ -1,4 +1,4 @@
add_library(mysqlbackendauth SHARED mysql_backend_auth.c)
add_library(mysqlbackendauth SHARED mysql_backend_auth.cc)
target_link_libraries(mysqlbackendauth maxscale-common mysqlcommon)
set_target_properties(mysqlbackendauth PROPERTIES VERSION "1.0.0")
install_module(mysqlbackendauth core)

View File

@ -50,7 +50,7 @@ typedef struct mysql_backend_auth
*/
void* auth_backend_create(void *instance)
{
mysql_backend_auth_t* mba = MXS_MALLOC(sizeof(*mba));
mysql_backend_auth_t* mba = static_cast<mysql_backend_auth_t*>(MXS_MALLOC(sizeof(*mba)));
if (mba)
{
@ -143,6 +143,8 @@ static bool auth_backend_ssl(DCB *dcb)
return dcb->server->server_ssl != NULL;
}
extern "C"
{
/**
* The module entry point routine. It is this routine that
* must populate the structure that is referred to as the
@ -189,3 +191,4 @@ MXS_MODULE* MXS_CREATE_MODULE()
return &info;
}
/*lint +e14 */
}