Add utime() support for directories on WIN32.
Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=6284
Reported by @grubba
_utime() on WIN32 doesn't support directories. From MSDN:
A return value of 1 indicates an error, in which case errno is set to one of the following values:
EACCES Path specifies directory or read-only file
Try to find an alternative API.
See also [bug #6220].