diff options
author | Pierre Ossman <ossman@cendio.se> | 2024-09-10 16:55:32 +0200 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2024-10-09 13:37:08 +0200 |
commit | 40df30d258ebfd24a447fababc649867c24513d8 (patch) | |
tree | e29c3abaac640eb1cfe951cae4ce4fe6896c8029 /win/rfb_win32/WMPoller.cxx | |
parent | 56b3460aa318b650f12833ba119fa6decb930148 (diff) | |
download | tigervnc-40df30d258ebfd24a447fababc649867c24513d8.tar.gz tigervnc-40df30d258ebfd24a447fababc649867c24513d8.zip |
Split SystemException to handle Windows
Windows has (at least) two error namespaces, both errno and
GetLastResult(). These overlap, so it is important we keep track of
which one we are dealing with.
To make things extra problematic, the BSD socket API normally uses
errno, but on Windows it has been mapped in to the GetLastResult()
namespace.
Try to keep better control of this by using separate classes for the
namespaces.
Diffstat (limited to 'win/rfb_win32/WMPoller.cxx')
-rw-r--r-- | win/rfb_win32/WMPoller.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/win/rfb_win32/WMPoller.cxx b/win/rfb_win32/WMPoller.cxx index 1e29d0c6..2c5917e9 100644 --- a/win/rfb_win32/WMPoller.cxx +++ b/win/rfb_win32/WMPoller.cxx @@ -57,7 +57,7 @@ bool rfb::win32::WMPoller::checkPollWindow(HWND w) { char buffer[128]; if (!GetClassName(w, buffer, 128)) - throw rdr::SystemException("unable to get window class:%u", GetLastError()); + throw rdr::Win32Exception("unable to get window class:%u", GetLastError()); if ((strcmp(buffer, "tty") != 0) && (strcmp(buffer, "ConsoleWindowClass") != 0)) { return false; |