From 9570ca098cd0e92d1eb6aabc00fb8cac9fddd442 Mon Sep 17 00:00:00 2001 From: Jakub Hrozek Date: Mon, 14 Sep 2009 13:03:57 +0200 Subject: Provide python bindings for sysdb Implement a set of python bindings for the sysdb with feature set similar to what is available in the tools. The primary consumers would be applications like system-config-users. Resolves: Ticket #102 --- server/util/util.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'server/util/util.h') diff --git a/server/util/util.h b/server/util/util.h index dda7527ee..ea7f44e83 100644 --- a/server/util/util.h +++ b/server/util/util.h @@ -104,6 +104,14 @@ void debug_fn(const char *format, ...); #define talloc_zfree(ptr) do { talloc_free(ptr); ptr = NULL; } while(0) #endif +#ifndef discard_const_p +#if defined(__intptr_t_defined) || defined(HAVE_INTPTR_T) +# define discard_const_p(type, ptr) ((type *)((intptr_t)(ptr))) +#else +# define discard_const_p(type, ptr) ((type *)(ptr)) +#endif +#endif + /* TODO: remove later * These functions are available in the latest tevent and are the ones that * should be used as tevent_req is rightfully opaque there */ -- cgit