Commit 3fe85b38 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Win32: struct stat is a macro so we need to include <sys/stat.h>

parent 452cf1c4
...@@ -63,6 +63,8 @@ static inline void vlc_rewinddir( DIR *dir ) ...@@ -63,6 +63,8 @@ static inline void vlc_rewinddir( DIR *dir )
} }
# undef rewinddir # undef rewinddir
# define rewinddir vlc_rewinddir # define rewinddir vlc_rewinddir
# include <sys/stat.h>
#endif #endif
struct stat; struct stat;
......
...@@ -243,6 +243,9 @@ int vlc_stat (const char *filename, struct stat *buf) ...@@ -243,6 +243,9 @@ int vlc_stat (const char *filename, struct stat *buf)
if (wpath == NULL) if (wpath == NULL)
return -1; return -1;
static_assert (sizeof (*buf) == sizeof (struct _stati64),
"Mismatched struct stat definition.");
int ret = _wstati64 (wpath, buf); int ret = _wstati64 (wpath, buf);
free (wpath); free (wpath);
return ret; return ret;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment