1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Bug#30695: An apostrophe ' in the comment of the ADD PARTITION

causes the Server to crash.

Post-pushbuild fix

Pushbuild genereted valgrind warnings.

Changed function to safer variant.
This commit is contained in:
mattiasj@mattiasj-laptop.(none)
2007-11-11 22:30:01 +01:00
parent 10df30f091
commit e7e18ac405

View File

@ -1866,7 +1866,7 @@ static int add_quoted_string(File fptr, const char *quotestr)
String escapedstr;
int err= add_string(fptr, "'");
err+= append_escaped(&escapedstr, &orgstr);
err+= add_string(fptr, escapedstr.c_ptr());
err+= add_string(fptr, escapedstr.c_ptr_safe());
return err + add_string(fptr, "'");
}