[MPlayer-cvslog] r35729 - in trunk: gui/wm/ws.c help/help_mp-de.h help/help_mp-en.h
ib
subversion at mplayerhq.hu
Thu Jan 10 16:24:39 CET 2013
Author: ib
Date: Thu Jan 10 16:24:39 2013
New Revision: 35729
Log:
Replace stderr output by mp_msg() error messages.
Additionally, enable translation of error text
and add doxygen comment.
Modified:
trunk/gui/wm/ws.c
Changes in other areas also in this revision:
Modified:
trunk/help/help_mp-de.h
trunk/help/help_mp-en.h
Modified: trunk/gui/wm/ws.c
==============================================================================
--- trunk/gui/wm/ws.c Thu Jan 10 13:23:17 2013 (r35728)
+++ trunk/gui/wm/ws.c Thu Jan 10 16:24:39 2013 (r35729)
@@ -191,17 +191,24 @@ void wsWindowDecoration(wsTWindow *win,
// Init X Window System.
// ----------------------------------------------------------------------------------------------
+/**
+ * @brief Inform about an X error that has occurred.
+ *
+ * @param display display
+ * @param event pointer to an X error event structure
+ *
+ * @return 0
+ */
static int wsErrorHandler(Display *display, XErrorEvent *event)
{
char type[128];
XGetErrorText(display, event->error_code, type, sizeof(type));
- fprintf(stderr, "[ws] Error in display.\n");
- fprintf(stderr, "[ws] Error code: %d ( %s )\n", event->error_code, type);
- fprintf(stderr, "[ws] Request code: %d\n", event->request_code);
- fprintf(stderr, "[ws] Minor code: %d\n", event->minor_code);
- fprintf(stderr, "[ws] Modules: %s\n", current_module ? current_module : "(NULL)");
+ mp_msg(MSGT_GPLAYER, MSGL_ERR, MSGTR_WS_XError);
+ mp_msg(MSGT_GPLAYER, MSGL_ERR, "[ws] Error code: %d - %s\n", event->error_code, type);
+ mp_msg(MSGT_GPLAYER, MSGL_DBG2, "[ws] Request code: %d (minor code: %d)\n", event->request_code, event->minor_code);
+ mp_msg(MSGT_GPLAYER, MSGL_DBG2, "[ws] MPlayer module: %s\n", current_module ? current_module : "(none)");
return 0;
}
More information about the MPlayer-cvslog
mailing list