ecore_con: fix use of FormatMessage for error reporting on windows.

@fix
This commit is contained in:
Guillaume Friloux 2015-01-30 14:09:34 +01:00 committed by Cedric BAIL
parent d6f08ba032
commit 388f8fbcaa
1 changed files with 4 additions and 3 deletions

View File

@ -2481,9 +2481,10 @@ _ecore_con_server_flush(Ecore_Con_Server *obj)
LPTSTR s;
FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |
FORMAT_MESSAGE_FROM_SYSTEM |
FORMAT_MESSAGE_FROM_STRING,
NULL, WSAGetLastError(), (DWORD)NULL, s, 0, NULL);
FORMAT_MESSAGE_FROM_SYSTEM,
NULL, WSAGetLastError(),
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
(LPTSTR)&s, 0, NULL);
ecore_con_event_server_error(obj, (char *)s);
free(s);
_ecore_con_server_kill(obj);