aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2015-02-09 20:34:59 +0100
committerPřemysl Janouch <p.janouch@gmail.com>2015-02-09 20:34:59 +0100
commit16dce195c167b607fa68739b4e0844849a1192b2 (patch)
treef5f124d5084ec7069dc3ec30cb6b70be55cbde22
parent4c888034f8117aa34d289f93e7f21ca1fcf67bea (diff)
downloadsensei-raw-ctl-16dce195c167b607fa68739b4e0844849a1192b2.tar.gz
sensei-raw-ctl-16dce195c167b607fa68739b4e0844849a1192b2.tar.xz
sensei-raw-ctl-16dce195c167b607fa68739b4e0844849a1192b2.zip
Cleaner up the previous commit
-rw-r--r--sensei-raw-ctl-gui.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/sensei-raw-ctl-gui.c b/sensei-raw-ctl-gui.c
index 3a7de24..aa22b13 100644
--- a/sensei-raw-ctl-gui.c
+++ b/sensei-raw-ctl-gui.c
@@ -30,15 +30,8 @@
#include "config.h"
#if ! GLIB_CHECK_VERSION (2, 34, 0)
-static void
-g_clear_pointer (void **pointer, void (*destroy) (void *))
-{
- if (*pointer)
- {
- destroy (*pointer);
- *pointer = NULL;
- }
-}
+#define g_clear_pointer(p, destroy) \
+ G_STMT_START if (*(p)) { (destroy) (*(p)); *(p) = NULL; } G_STMT_END
#endif // ! GLIB_CHECK_VERSION (2, 34)
/** User interface string for GtkBuilder. */