Fix basic parameters

The ssl parameters were defined as strings even thought they were actually
enums. The events parameter was also a string even though it was an enum.

Also added the missing "all" value to the events enum. This fixes the
regression of scripts not being launched on all events by default.

Moved the definition of the default version string where it should be and
removed the empty value check.
This commit is contained in:
Markus Mäkelä
2018-08-09 16:38:38 +03:00
parent 390c749d4a
commit 7c627144fb
5 changed files with 15 additions and 19 deletions

View File

@ -241,17 +241,8 @@ int MySQLSendHandshake(DCB* dcb)
MySQLProtocol *protocol = DCB_PROTOCOL(dcb, MySQLProtocol);
GWBUF *buf;
/* get the version string from service property if available*/
if (dcb->service->version_string[0])
{
version_string = dcb->service->version_string;
len_version_string = strlen(version_string);
}
else
{
version_string = (char*)GW_MYSQL_VERSION;
len_version_string = strlen(GW_MYSQL_VERSION);
}
version_string = dcb->service->version_string;
len_version_string = strlen(version_string);
gw_generate_random_str(server_scramble, GW_MYSQL_SCRAMBLE_SIZE);