hw/xwin: Remove left-over pthread_exit() in clipboard code

Commit c1bf3baa44 removed all but one of the
pthread_exit() calls which used to call winClipboardThreadExit()

Fix the final remaining one to exit via done label on IOError instead.

Also fix a comment and report pre-flush failure to log, but do not exit

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
This commit is contained in:
Jon TURNEY 2014-01-01 17:54:48 +00:00
parent d3427717f2
commit 6343b531d7

View File

@ -141,7 +141,7 @@ winClipboardProc(void *pvNotUsed)
else if (iReturn == WIN_JMP_ERROR_IO) {
/* TODO: Cleanup the Win32 window and free any allocated memory */
ErrorF("winClipboardProc - setjmp returned for IO Error Handler.\n");
pthread_exit(NULL);
goto winClipboardProc_Done;
}
/* Use our generated cookie for authentication */
@ -184,7 +184,7 @@ winClipboardProc(void *pvNotUsed)
goto winClipboardProc_Done;
}
/* Save the display in the screen privates */
/* Save the display in a global used by the wndproc */
g_pClipboardDisplay = pDisplay;
ErrorF("winClipboardProc - XOpenDisplay () returned and "
@ -269,8 +269,9 @@ winClipboardProc(void *pvNotUsed)
winClipboardFlushXEvents(hwnd, iWindow, pDisplay, fUseUnicode);
/* Pre-flush Windows messages */
if (!winClipboardFlushWindowsMessageQueue(hwnd))
return 0;
if (!winClipboardFlushWindowsMessageQueue(hwnd)) {
ErrorF("winClipboardProc - winClipboardFlushWindowsMessageQueue failed\n");
}
/* Signal that the clipboard client has started */
g_fClipboardStarted = TRUE;