crt: Fix _wstat() for crtdll.dll/msvcrt10.dll when called on directory

CRT _fstat function returns S_IFREG for directories, but CRT _stat function
returns S_IFDIR for directories. mingw-w64 fstat functions fixes this
_fstat issues, so use fstat for _wstat emulation used for crtdll.dll and
msvcrt10.dll builds.

This change fixes the t_stat_slash test when compiled against crtdll.dll.

Signed-off-by: LIU Hao <lh_mouse@126.com>
1 file changed