summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2007-01-20 14:53:59 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2007-01-20 14:53:59 +0000
commit89edbea0fde48f3e91b634589299f5c0f13e1543 (patch)
tree8dec6f044bc9ea19b3fbfefa1a8800d18e7a0fb6
parent6906a81304d989f0039896903a2496e63518898c (diff)
Get rid of g_idle_add
-rw-r--r--eglib/gmain.c6
-rw-r--r--eglib/gmain.h1
-rw-r--r--hcid/dbus-service.c20
3 files changed, 3 insertions, 24 deletions
diff --git a/eglib/gmain.c b/eglib/gmain.c
index ea3adebd..a5e46a3a 100644
--- a/eglib/gmain.c
+++ b/eglib/gmain.c
@@ -544,12 +544,6 @@ guint g_timeout_add(guint interval, GSourceFunc function, gpointer data)
return t->id;
}
-guint g_idle_add(GSourceFunc func, gpointer user_data)
-{
- /* Not implemented */
- return 0;
-}
-
/* GError */
void g_error_free(GError *err)
{
diff --git a/eglib/gmain.h b/eglib/gmain.h
index 7080c687..0ad103d9 100644
--- a/eglib/gmain.h
+++ b/eglib/gmain.h
@@ -107,7 +107,6 @@ void g_main_loop_quit(GMainLoop *loop);
void g_main_loop_unref(GMainLoop *loop);
guint g_timeout_add(guint interval, GSourceFunc function, gpointer data);
gboolean g_source_remove(guint tag);
-guint g_idle_add(GSourceFunc func, gpointer user_data);
/* GError */
diff --git a/hcid/dbus-service.c b/hcid/dbus-service.c
index e1be0797..f1e3d05f 100644
--- a/hcid/dbus-service.c
+++ b/hcid/dbus-service.c
@@ -913,21 +913,6 @@ static void service_notify(int action, const char *name, void *user_data)
}
}
-static gboolean startup_services(gpointer user_data)
-{
- GSList *l;
-
- for (l = services; l != NULL; l = l->next) {
- struct service *service = l->data;
-
- if (service->autostart)
- service_start(service, get_dbus_connection());
-
- }
-
- return FALSE;
-}
-
int init_services(const char *path)
{
DIR *d;
@@ -964,14 +949,15 @@ int init_services(const char *path)
service_free(service);
continue;
}
+
+ if (service->autostart)
+ service_start(service, get_dbus_connection());
}
closedir(d);
notify_add(path, service_notify, NULL);
- g_idle_add(startup_services, NULL);
-
return 0;
}