From 25aa23067133fa80df009c2245742b3b7749c2e5 Mon Sep 17 00:00:00 2001 From: ChrisTX Date: Sat, 23 Mar 2013 23:52:51 +0100 Subject: Win32: Rewrite the service wrapper Edited original commit to pass MAX_PATH as nSize to GetModuleFileNameA() instead of 101 after approval from author @ChrisTX (Attila Molnar) Fixes #404 reported by @crchauffe --- win/inspircd_win32wrapper.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'win/inspircd_win32wrapper.h') diff --git a/win/inspircd_win32wrapper.h b/win/inspircd_win32wrapper.h index d60276b88..75404ef8b 100644 --- a/win/inspircd_win32wrapper.h +++ b/win/inspircd_win32wrapper.h @@ -186,5 +186,20 @@ void ::operator delete(void * ptr); #define DISABLE_WRITEV +#include + +class CWin32Exception : public std::exception +{ +public: + CWin32Exception(); + CWin32Exception(const CWin32Exception& other); + virtual const char* what() const throw(); + DWORD GetErrorCode(); + +private: + char szErrorString[500]; + DWORD dwErrorCode; +}; + #endif -- cgit v1.2.3