winpr: include Windows headers in <winpr/shell.h>
This header file (currently) provides definitions of FILEDESCRIPTOR structure and GetUserProfileDirectory() function. However, it does so only when included on non-Windows platforms. The code which includes it fails to build on Windows because the definitions are absent and it causes weird compilation errors (like FILEDESCRIPTOR being treated as the name of a function argument). Inculde <shlobj.h> to get FILEDESCRIPTOR and <userenv.h> for the GetUserProfileDirectory() function. (And hope that this will not pull more Windows headers than we need in the files which include <winpr/shell.h>.)
This commit is contained in:
parent
44b04cafef
commit
d341973247
@ -27,7 +27,12 @@
|
||||
#include <winpr/winpr.h>
|
||||
#include <winpr/wtypes.h>
|
||||
|
||||
#ifndef _WIN32
|
||||
#ifdef _WIN32
|
||||
|
||||
#include <shlobj.h>
|
||||
#include <userenv.h>
|
||||
|
||||
#else
|
||||
|
||||
/* Shell clipboard formats */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user