mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
fix "enforce no trailing \n in Diagnostic_area messages"
cannot have an assert in Warning_info::push_warning()
because SQL command SIGNAL can set an absolutely arbitrary
message, even an empty one or ending with '\n'
move the assert into push_warning() and my_message_sql().
followup for 9508a44c37
This commit is contained in:
@ -3086,6 +3086,8 @@ err:
|
||||
}
|
||||
else if (info->errmsg != NULL)
|
||||
safe_strcpy(info->error_text, sizeof(info->error_text), info->errmsg);
|
||||
else if (info->error_text[0] == 0)
|
||||
safe_strcpy(info->error_text, sizeof(info->error_text), ER(info->error));
|
||||
|
||||
my_message(info->error, info->error_text, MYF(0));
|
||||
|
||||
|
Reference in New Issue
Block a user