You've already forked mariadb-connector-c
mirror of
https://github.com/mariadb-corporation/mariadb-connector-c.git
synced 2025-08-08 14:02:17 +03:00
don't use the output printf buffer as a %s parameter
followup for ebcb9eca29
This commit is contained in:
@@ -1808,10 +1808,14 @@ restart:
|
|||||||
else if (IS_MYSQL_ERROR(code) || IS_MARIADB_ERROR(code))
|
else if (IS_MYSQL_ERROR(code) || IS_MARIADB_ERROR(code))
|
||||||
; /* not forged - generated on the client side */
|
; /* not forged - generated on the client side */
|
||||||
else if (mysql->options.use_ssl)
|
else if (mysql->options.use_ssl)
|
||||||
|
{
|
||||||
|
char last_error[sizeof(mysql->net.last_error)];
|
||||||
|
strcpy(last_error, mysql->net.last_error);
|
||||||
my_set_error(mysql, CR_CONNECTION_ERROR, SQLSTATE_UNKNOWN,
|
my_set_error(mysql, CR_CONNECTION_ERROR, SQLSTATE_UNKNOWN,
|
||||||
"Received error packet before completion of TLS handshake. "
|
"Received error packet before completion of TLS handshake. "
|
||||||
"The authenticity of the following error cannot be verified:\n%d - %s",
|
"The authenticity of the following error cannot be verified: %d - %s",
|
||||||
code, mysql->net.last_error);
|
code, last_error);
|
||||||
|
}
|
||||||
|
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user