diff options
Diffstat (limited to 'cppe/src/IceE/ThreadException.cpp')
-rw-r--r-- | cppe/src/IceE/ThreadException.cpp | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/cppe/src/IceE/ThreadException.cpp b/cppe/src/IceE/ThreadException.cpp index 0cde7200156..1915f7f6431 100644 --- a/cppe/src/IceE/ThreadException.cpp +++ b/cppe/src/IceE/ThreadException.cpp @@ -32,33 +32,33 @@ IceUtil::ThreadSyscallException::toString() const string out = Exception::toString(); if(_error != 0) { - out += ":\nthread syscall exception: "; + out += ":\nthread syscall exception: "; #ifdef _WIN32_WCE - out += Ice::printfToString("thread error: %d", _error); + out += Ice::printfToString("thread error: %d", _error); #elif defined(_WIN32) - LPVOID lpMsgBuf = 0; - DWORD ok = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | - FORMAT_MESSAGE_FROM_SYSTEM | - FORMAT_MESSAGE_IGNORE_INSERTS, - NULL, - _error, - MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language - (LPTSTR)&lpMsgBuf, - 0, - NULL); - - if(ok) - { - LPCTSTR msg = (LPCTSTR)lpMsgBuf; - assert(msg && strlen((char*)msg) > 0); - out += reinterpret_cast<const char*>(msg); - LocalFree(lpMsgBuf); - } - else - { - out += "unknown thread error: "; - out += Ice::printfToString("error=%d", _error); - } + LPVOID lpMsgBuf = 0; + DWORD ok = FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER | + FORMAT_MESSAGE_FROM_SYSTEM | + FORMAT_MESSAGE_IGNORE_INSERTS, + NULL, + _error, + MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language + (LPTSTR)&lpMsgBuf, + 0, + NULL); + + if(ok) + { + LPCTSTR msg = (LPCTSTR)lpMsgBuf; + assert(msg && strlen((char*)msg) > 0); + out += reinterpret_cast<const char*>(msg); + LocalFree(lpMsgBuf); + } + else + { + out += "unknown thread error: "; + out += Ice::printfToString("error=%d", _error); + } #else out += strerror(_error); #endif |