summaryrefslogtreecommitdiff
path: root/glib
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2012-01-25 08:53:05 -0500
committerMatthias Clasen <mclasen@redhat.com>2012-01-25 16:15:18 -0500
commitef159af00f723f46658f46af03ea67185dae9988 (patch)
tree9672d3d7bc30ae55c45d552e5d626e3d8407b1a6 /glib
parent12060df9f17a48cd4c7fda27a0af70c17c308ad9 (diff)
downloadglib-ef159af00f723f46658f46af03ea67185dae9988.tar.gz
Use G_SOURCE_CONTINUE/REMOVE internally
Now that we have these macros, we should use them. This commit covers everything in glib/.
Diffstat (limited to 'glib')
-rw-r--r--glib/gmain.c2
-rw-r--r--glib/tests/mainloop.c2
-rw-r--r--glib/tests/spawn-multithreaded.c2
-rw-r--r--glib/tests/spawn-singlethread.c2
-rw-r--r--glib/tests/timeout.c4
-rw-r--r--glib/tests/unix.c6
6 files changed, 10 insertions, 8 deletions
diff --git a/glib/gmain.c b/glib/gmain.c
index 4a79cb935..b1e3eee53 100644
--- a/glib/gmain.c
+++ b/glib/gmain.c
@@ -2358,7 +2358,7 @@ g_main_current_source (void)
* self->idle_id = 0;
* GDK_THREADS_LEAVE (<!-- -->);
*
- * return FALSE;
+ * return G_SOURCE_REMOVE;
* }
*
* static void
diff --git a/glib/tests/mainloop.c b/glib/tests/mainloop.c
index 980f7f5fc..7372f9737 100644
--- a/glib/tests/mainloop.c
+++ b/glib/tests/mainloop.c
@@ -219,7 +219,7 @@ call_func (gpointer data)
{
func (g_thread_self ());
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static gpointer
diff --git a/glib/tests/spawn-multithreaded.c b/glib/tests/spawn-multithreaded.c
index 534766b2a..3f632f4f7 100644
--- a/glib/tests/spawn-multithreaded.c
+++ b/glib/tests/spawn-multithreaded.c
@@ -104,7 +104,7 @@ on_child_exited (GPid pid,
if (data->child_exited && data->stdout_done)
g_main_loop_quit (data->loop);
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static gboolean
diff --git a/glib/tests/spawn-singlethread.c b/glib/tests/spawn-singlethread.c
index f29ecb8ab..42d88e62e 100644
--- a/glib/tests/spawn-singlethread.c
+++ b/glib/tests/spawn-singlethread.c
@@ -46,7 +46,7 @@ on_child_exited (GPid pid,
if (data->child_exited && data->stdout_done)
g_main_loop_quit (data->loop);
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static gboolean
diff --git a/glib/tests/timeout.c b/glib/tests/timeout.c
index 88d5ffe66..2d78723d8 100644
--- a/glib/tests/timeout.c
+++ b/glib/tests/timeout.c
@@ -8,13 +8,15 @@ stop_waiting (gpointer data)
{
g_main_loop_quit (loop);
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static gboolean
function (gpointer data)
{
g_assert_not_reached ();
+
+ return G_SOURCE_REMOVE;
}
static void
diff --git a/glib/tests/unix.c b/glib/tests/unix.c
index feb2bb464..77ee61e08 100644
--- a/glib/tests/unix.c
+++ b/glib/tests/unix.c
@@ -71,7 +71,7 @@ on_sig_received (gpointer user_data)
GMainLoop *loop = user_data;
g_main_loop_quit (loop);
sig_received = TRUE;
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static gboolean
@@ -80,7 +80,7 @@ sig_not_received (gpointer data)
GMainLoop *loop = data;
(void) loop;
g_error ("Timed out waiting for signal");
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static gboolean
@@ -88,7 +88,7 @@ exit_mainloop (gpointer data)
{
GMainLoop *loop = data;
g_main_loop_quit (loop);
- return FALSE;
+ return G_SOURCE_REMOVE;
}
static void