xcb: xcb_error() no longer prefixes error message with "XCB: "

This commit is contained in:
Daniel Eklöf 2019-01-16 16:27:25 +01:00
parent bf558eca1b
commit 77f8e6fa28
3 changed files with 4 additions and 4 deletions

2
bar.c
View file

@ -579,7 +579,7 @@ run(struct bar_run_context *run_ctx)
{
switch (XCB_EVENT_RESPONSE_TYPE(e)) {
case 0:
LOG_ERR("%s", xcb_error((const xcb_generic_error_t *)e));
LOG_ERR("XCB: %s", xcb_error((const xcb_generic_error_t *)e));
break;
case XCB_EXPOSE:

View file

@ -244,7 +244,7 @@ run(struct module *mod)
{
switch (XCB_EVENT_RESPONSE_TYPE(_e)) {
case 0:
LOG_ERR("%s", xcb_error((const xcb_generic_error_t *)_e));
LOG_ERR("XCB: %s", xcb_error((const xcb_generic_error_t *)_e));
case XCB_PROPERTY_NOTIFY: {
xcb_property_notify_event_t *e = (xcb_property_notify_event_t *)_e;

4
xcb.c
View file

@ -218,12 +218,12 @@ xcb_error(const xcb_generic_error_t *error)
err_context, error->error_code, &extension);
snprintf(msg, sizeof(msg),
"XCB: %s (%s), code %s (%s), sequence %u",
"%s (%s), code %s (%s), sequence %u",
major, minor != NULL ? minor : "no minor",
name, extension != NULL ? extension : "no extension",
error->sequence);
#else
snprintf(msg, sizeof(msg), "XCB: op %hhu:%hu, code %hhu, sequence %hu",
snprintf(msg, sizeof(msg), "op %hhu:%hu, code %hhu, sequence %hu",
error->major_code, error->minor_code, error->error_code,
error->sequence);
#endif