Fix windows stat on files with trailing /