diff options
| author | Dana Jansens <danakj@orodu.net> | 2007-05-27 22:39:57 +0000 |
|---|---|---|
| committer | Dana Jansens <danakj@orodu.net> | 2007-05-27 22:39:57 +0000 |
| commit | 5395d30623c6285d58d8ab2390fed1e5de90a459 (patch) | |
| tree | adbf3a4e3911f1b02560c5ad4fbe69ca4a93200c /openbox | |
| parent | 65bf23c27d99fd1d025c28cd3cae5bf918f8ca8b (diff) | |
put xerrors in the debug output when they are being ignored
Diffstat (limited to 'openbox')
| -rw-r--r-- | openbox/xerror.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/openbox/xerror.c b/openbox/xerror.c index 3de593b8..14c0ecd6 100644 --- a/openbox/xerror.c +++ b/openbox/xerror.c @@ -27,20 +27,22 @@ gboolean xerror_occured = FALSE; gint xerror_handler(Display *d, XErrorEvent *e) { - xerror_occured = TRUE; #ifdef DEBUG - if (!xerror_ignore) { - gchar errtxt[128]; + gchar errtxt[128]; - XGetErrorText(d, e->error_code, errtxt, 127); + XGetErrorText(d, e->error_code, errtxt, 127); + if (!xerror_ignore) { if (e->error_code == BadWindow) /*g_message(_("X Error: %s\n"), errtxt)*/; else g_error(_("X Error: %s"), errtxt); - } + } else + ob_debug("XError code %d '%s'\n", e->error_code, errtxt); #else (void)d; (void)e; #endif + + xerror_occured = TRUE; return 0; } |
