
#ifndef THREAD_GUARD_H
#define THREAD_GUARD_H

#include <glib.h>
#include <glib-object.h>

typedef gpointer (* GuardedCallback)(gpointer user_data);

void guard_init(void);

void guarded_invoke(GClosure *closure, GValue *return_value, guint n_param_values, const GValue *param_values, gpointer invocation_hint);
gpointer guarded_call(GuardedCallback function, gpointer user_data);

#endif

