Added windows-specific fixes, because strftime's implementation is different.