Fix for missing '\'' char detection
Fix for missing ' char detection
This commit is contained in:
@ -3135,9 +3135,9 @@ blr_set_master_hostname(ROUTER_INSTANCE *router, char *hostname) {
|
|||||||
ptr = strchr(hostname, '\'');
|
ptr = strchr(hostname, '\'');
|
||||||
if (ptr)
|
if (ptr)
|
||||||
ptr++;
|
ptr++;
|
||||||
|
else
|
||||||
|
ptr = hostname;
|
||||||
end = strchr(ptr, '\'');
|
end = strchr(ptr, '\'');
|
||||||
|
|
||||||
if (end)
|
if (end)
|
||||||
*end ='\0';
|
*end ='\0';
|
||||||
|
|
||||||
@ -3206,6 +3206,8 @@ blr_set_master_logfile(ROUTER_INSTANCE *router, char *filename, char *error) {
|
|||||||
file_ptr = strchr(filename, '\'');
|
file_ptr = strchr(filename, '\'');
|
||||||
if (file_ptr)
|
if (file_ptr)
|
||||||
file_ptr++;
|
file_ptr++;
|
||||||
|
else
|
||||||
|
file_ptr = filename;
|
||||||
|
|
||||||
end = strchr(file_ptr, '\'');
|
end = strchr(file_ptr, '\'');
|
||||||
if (end)
|
if (end)
|
||||||
@ -3395,6 +3397,8 @@ blr_set_master_user(ROUTER_INSTANCE *router, char *user) {
|
|||||||
ptr = strchr(user, '\'');
|
ptr = strchr(user, '\'');
|
||||||
if (ptr)
|
if (ptr)
|
||||||
ptr++;
|
ptr++;
|
||||||
|
else
|
||||||
|
ptr = user;
|
||||||
|
|
||||||
end = strchr(ptr, '\'');
|
end = strchr(ptr, '\'');
|
||||||
if (end)
|
if (end)
|
||||||
@ -3430,6 +3434,8 @@ blr_set_master_password(ROUTER_INSTANCE *router, char *password) {
|
|||||||
ptr = strchr(password, '\'');
|
ptr = strchr(password, '\'');
|
||||||
if (ptr)
|
if (ptr)
|
||||||
ptr++;
|
ptr++;
|
||||||
|
else
|
||||||
|
ptr = password;
|
||||||
|
|
||||||
end = strchr(ptr, '\'');
|
end = strchr(ptr, '\'');
|
||||||
if (end)
|
if (end)
|
||||||
|
Reference in New Issue
Block a user