summaryrefslogtreecommitdiff
path: root/src/system/Error.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'src/system/Error.hxx')
-rw-r--r--src/system/Error.hxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/system/Error.hxx b/src/system/Error.hxx
index 289ceeaf8..aa017966b 100644
--- a/src/system/Error.hxx
+++ b/src/system/Error.hxx
@@ -47,7 +47,9 @@ FormatSystemError(std::error_code code, const char *fmt,
#ifdef _WIN32
-#include <windows.h>
+#include <errhandlingapi.h> // for GetLastError()
+#include <windef.h> // for HWND (needed by winbase.h)
+#include <winbase.h> // for FormatMessageA()
static inline std::system_error
MakeLastError(DWORD code, const char *msg) noexcept