From 1ed34fed3390e10ff67981c4470f46c6ce1e2a6e Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 29 Feb 2008 17:56:50 +0400 Subject: Bug#23924 general_log truncates queries with character set introducers. Problem: logging of utf8-incompatible binary strings didn't work Fix: hex-encoding of incompatible sequences. mysql-test/r/log_tables.result: Adding test mysql-test/t/log_tables.test: Adding test sql/field.cc: Copying with hex escaping sql/field.h: New field flag sql/log.cc: Marking the column "general_log.argument" as hex-escaping field. sql/sql_string.cc: New function to copy strings with hex-encoding of incompatible characters. sql/sql_string.h: Prototype for the new function --- sql/log.cc | 1 + 1 file changed, 1 insertion(+) (limited to 'sql/log.cc') diff --git a/sql/log.cc b/sql/log.cc index 9b5b2ae5a6c..328aaa45f3f 100644 --- a/sql/log.cc +++ b/sql/log.cc @@ -418,6 +418,7 @@ bool Log_to_csv_event_handler:: A positive return value in store() means truncation. Still logging a message in the log in this case. */ + table->field[5]->flags|= FIELDFLAG_HEX_ESCAPE; if (table->field[5]->store(sql_text, sql_text_len, client_cs) < 0) goto err; -- cgit v1.2.1