From e54d2195d7e40c39773d5e212ea901146df43ee3 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Tue, 16 Sep 2008 18:11:04 +0200 Subject: [PATCH] xutil: inline xutil_error_delete Signed-off-by: Julien Danjou --- common/xutil.c | 8 -------- common/xutil.h | 9 ++++++++- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/common/xutil.c b/common/xutil.c index 2e818aa6..9aaf2b8a 100644 --- a/common/xutil.c +++ b/common/xutil.c @@ -332,14 +332,6 @@ xutil_error_get(const xcb_generic_error_t *e) return err; } -void -xutil_error_delete(xutil_error_t *err) -{ - p_delete(&err->error_label); - p_delete(&err->request_label); - p_delete(&err); -} - /** Link a name to a key symbol */ typedef struct { diff --git a/common/xutil.h b/common/xutil.h index fb4b3fb3..e9e6e960 100644 --- a/common/xutil.h +++ b/common/xutil.h @@ -112,11 +112,18 @@ typedef struct } xutil_error_t; xutil_error_t *xutil_error_get(const xcb_generic_error_t *); -void xutil_error_delete(xutil_error_t *); xcb_keysym_t xutil_key_mask_fromstr(const char *); unsigned int xutil_button_fromint(int); xcb_cursor_t xutil_cursor_new(xcb_connection_t *, unsigned int); +static inline void +xutil_error_delete(xutil_error_t *err) +{ + p_delete(&err->error_label); + p_delete(&err->request_label); + p_delete(&err); +} + /* Get the informations about the screen. * \param c X connection. * \param screen Screen number.