qt: add device preferences for mmdevice
[vlc.git] / contrib / src / asdcplib / win32-dirent.patch
blobb137426aa1efdb3aadf80ebffef0600c659051b1
1 --- asdcplib/src/KM_fileio.h.orig 2017-02-14 17:17:22.745776193 +0100
2 +++ asdcplib/src/KM_fileio.h 2017-02-14 17:17:29.713782420 +0100
3 @@ -37,7 +37,6 @@
5 #ifdef KM_WIN32
6 # include <io.h>
7 -# include "dirent_win.h"
8 #else
9 # include <dirent.h>
10 # include <unistd.h>
11 @@ -46,6 +45,7 @@
12 #include <regex.h>
13 #endif
15 +#include <dirent.h>
16 #include <sys/stat.h>
19 --- asdcplib/src/KM_fileio.cpp.orig 2017-02-14 17:16:18.297717750 +0100
20 +++ asdcplib/src/KM_fileio.cpp 2017-02-14 17:17:48.833799420 +0100
21 @@ -1478,7 +1478,7 @@
22 if ( m_Handle == 0 )
23 return RESULT_FILEOPEN;
25 -#if defined(__sun) && defined(__SVR4)
26 +#if (defined(__sun) && defined(__SVR4)) || defined(_WIN32)
27 struct stat s;
28 #endif
29 struct dirent* entry;
30 @@ -1493,7 +1493,7 @@
32 next_item_name.assign(entry->d_name, strlen(entry->d_name));
34 -#if defined(__sun) && defined(__SVR4)
35 +#if (defined(__sun) && defined(__SVR4)) || defined(_WIN32)
37 stat(entry->d_name, &s);
39 @@ -1506,10 +1506,11 @@
40 case S_IFREG:
41 next_item_type = DET_FILE;
42 break;
44 +#ifndef _WIN32
45 case S_IFLNK:
46 next_item_type = DET_LINK;
47 break;
48 +#endif
50 default:
51 next_item_type = DET_DEV;