Commit adb32fb4 authored by rswindell's avatar rswindell
Browse files

Use Microsoft magic to "ignore regular line breaks in the message definition...

Use Microsoft magic to "ignore regular line breaks in the message definition text." of socket error strings on Windows:
strips the embedded line-feeds from the socket error description.
parent 8ea8d21f
......@@ -506,7 +506,7 @@ DLLEXPORT const char* socket_strerror(int error_number)
{
static char msg[256];
FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, // dwFlags
FormatMessage(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS | FORMAT_MESSAGE_MAX_WIDTH_MASK, // dwFlags
NULL, // lpSource
error_number, // dwMessageId
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // dwLanguageId
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment