summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
authorunknown <serg@serg.mylan>2004-09-06 22:20:40 +0200
committerunknown <serg@serg.mylan>2004-09-06 22:20:40 +0200
commit982a78829af9bc579fc884e641f5ec10cb1f478e (patch)
treed309acd7dfd1112de0a893b4c4f43dad6ea970ba /sql/log.cc
parent50bde4930938fc26a2e2a01aa13ef9d9f344d8a4 (diff)
downloadmariadb-git-982a78829af9bc579fc884e641f5ec10cb1f478e.tar.gz
bug#5389 merge.test fails on qnx - uninitalized variable in myrg_open()
myisammrg/myrg_open.c: backport from 4.1 mysql-test/r/union.result: after merge fix mysql-test/t/union.test: after merge fix sql/log.cc: backward compatibility: inhibit severity labels in error log
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc20
1 files changed, 13 insertions, 7 deletions
diff --git a/sql/log.cc b/sql/log.cc
index 55ef2e72960..151d613f637 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -1221,7 +1221,7 @@ bool MYSQL_LOG::write(Log_event* event_info)
if (e.write(file))
goto err;
}
-#if MYSQL_VERSION_ID < 40100
+#if MYSQL_VERSION_ID < 40100
if (thd->variables.convert_set)
{
Query_log_event e(thd, "SET CHARACTER SET DEFAULT", 25, 0);
@@ -1761,15 +1761,21 @@ void print_buffer_to_file(enum loglevel level, const char *buffer)
skr=time(NULL);
localtime_r(&skr, &tm_tmp);
start=&tm_tmp;
+#if MYSQL_VERSION_ID > 40100
fprintf(stderr, "%02d%02d%02d %2d:%02d:%02d [%s] %s\n",
- start->tm_year % 100,
- start->tm_mon+1,
- start->tm_mday,
- start->tm_hour,
- start->tm_min,
- start->tm_sec,
+#else
+ fprintf(stderr, "%02d%02d%02d %2d:%02d:%02d %s\n",
+#endif
+ start->tm_year % 100,
+ start->tm_mon+1,
+ start->tm_mday,
+ start->tm_hour,
+ start->tm_min,
+ start->tm_sec,
+#if MYSQL_VERSION_ID > 40100
(level == ERROR_LEVEL ? "ERROR" : level == WARNING_LEVEL ?
"WARNING" : "INFORMATION"),
+#endif
buffer);
fflush(stderr);