Commit df3887f9 authored by Jim Winstead's avatar Jim Winstead

The get_date() function in mysys interpreted the GETDATE_GMT option

backwards, which resulted in the incorrect time being reported at the
end of mysqldump. (Bug #44424, patch by Andrew Hutchings)
parent 3fe1d299
......@@ -45,15 +45,15 @@ void get_date(register my_string to, int flag, time_t date)
skr=date ? (time_t) date : time((time_t*) 0);
#if defined(HAVE_LOCALTIME_R) && defined(_REENTRANT)
if (flag & GETDATE_GMT)
localtime_r(&skr,&tm_tmp);
else
gmtime_r(&skr,&tm_tmp);
else
localtime_r(&skr,&tm_tmp);
start_time= &tm_tmp;
#else
if (flag & GETDATE_GMT)
start_time= localtime(&skr);
else
start_time= gmtime(&skr);
else
start_time= localtime(&skr);
#endif
if (flag & GETDATE_SHORT_DATE)
sprintf(to,"%02d%02d%02d",
......
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