[vlc-commits] XCB: make CheckError() return the actual error code
Rémi Denis-Courmont
git at videolan.org
Mon Aug 8 18:22:25 CEST 2011
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Mon Aug 8 18:49:02 2011 +0300| [8516a403b9225cd64dcdddfee8b65adba5ab2ec4] | committer: Rémi Denis-Courmont
XCB: make CheckError() return the actual error code
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=8516a403b9225cd64dcdddfee8b65adba5ab2ec4
---
modules/video_output/xcb/events.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/modules/video_output/xcb/events.c b/modules/video_output/xcb/events.c
index e68a35e..fe29ec3 100644
--- a/modules/video_output/xcb/events.c
+++ b/modules/video_output/xcb/events.c
@@ -45,11 +45,14 @@ int CheckError (vout_display_t *vd, xcb_connection_t *conn,
err = xcb_request_check (conn, ck);
if (err)
{
- msg_Err (vd, "%s: X11 error %d", str, err->error_code);
+ int code = err->error_code;
+
free (err);
- return VLC_EGENERIC;
+ msg_Err (vd, "%s: X11 error %d", str, code);
+ assert (code != 0);
+ return code;
}
- return VLC_SUCCESS;
+ return 0;
}
/**
More information about the vlc-commits
mailing list