fix format_date() bug in cygwin