dispatcher/trivial: move code

Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
Thomas Haller 2014-06-12 18:08:59 +02:00 committed by Dan Williams
parent 141ff20fe8
commit 4830cd6115

View file

@ -37,6 +37,18 @@
static gboolean do_dispatch = TRUE;
static GHashTable *requests = NULL;
typedef struct {
const char *dir;
GFileMonitor *monitor;
gboolean has_scripts;
} Monitor;
static Monitor monitors[3] = {
{ NMD_SCRIPT_DIR_DEFAULT, NULL, TRUE },
{ NMD_SCRIPT_DIR_PRE_UP, NULL, TRUE },
{ NMD_SCRIPT_DIR_PRE_DOWN, NULL, TRUE }
};
static void
dump_object_to_props (GObject *object, GHashTable *hash)
{
@ -643,18 +655,6 @@ nm_dispatcher_call_cancel (guint call_id)
}
}
typedef struct {
const char *dir;
GFileMonitor *monitor;
gboolean has_scripts;
} Monitor;
static Monitor monitors[3] = {
{ NMD_SCRIPT_DIR_DEFAULT, NULL, TRUE },
{ NMD_SCRIPT_DIR_PRE_UP, NULL, TRUE },
{ NMD_SCRIPT_DIR_PRE_DOWN, NULL, TRUE }
};
static void
dispatcher_dir_changed (GFileMonitor *monitor,
GFile *file,