Commit 68ad3413 authored by heikki@donna.mysql.fi's avatar heikki@donna.mysql.fi

Merge heikki@work.mysql.com:/home/my/mysql

into donna.mysql.fi:/home/heikki/mysqle
parents acf598c5 96176f16
......@@ -38,6 +38,7 @@ AC_CHECK_HEADERS(aio.h sched.h)
AC_CHECK_SIZEOF(int, 4)
AC_CHECK_FUNCS(sched_yield)
AC_CHECK_FUNCS(fdatasync)
AC_CHECK_FUNCS(localtime_r)
#AC_C_INLINE Already checked in MySQL
AC_C_BIGENDIAN
......
......@@ -72,19 +72,25 @@ ut_print_timestamp(
#else
struct tm cal_tm;
struct tm* cal_tm_ptr;
time_t tm;
time(&tm);
#ifdef HAVE_LOCALTIME_R
localtime_r(&tm, &cal_tm);
cal_tm_ptr = &cal_tm;
#else
cal_tm_ptr = localtime(&tm);
#endif
fprintf(file,"%02d%02d%02d %2d:%02d:%02d",
cal_tm.tm_year % 100,
cal_tm.tm_mon+1,
cal_tm.tm_mday,
cal_tm.tm_hour,
cal_tm.tm_min,
cal_tm.tm_sec);
cal_tm_ptr->tm_year % 100,
cal_tm_ptr->tm_mon+1,
cal_tm_ptr->tm_mday,
cal_tm_ptr->tm_hour,
cal_tm_ptr->tm_min,
cal_tm_ptr->tm_sec);
#endif
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment