summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Withnall <pwithnall@endlessos.org>2021-09-24 07:57:49 +0100
committerPhilip Withnall <pwithnall@endlessos.org>2021-09-24 07:57:49 +0100
commitef72bed1c0ad692b9be4615c44d4a69e91ab9fd0 (patch)
tree6f4578526ff580bfa15c008405458db2bf7a32fe
parent3b4a34c29a1d6dcda611be8433e0b3b2266c055d (diff)
downloadglib-ef72bed1c0ad692b9be4615c44d4a69e91ab9fd0.tar.gz
gtask: Document dependency on GMainContext more explicitly
Signed-off-by: Philip Withnall <pwithnall@endlessos.org> Fixes: #2404
-rw-r--r--gio/gtask.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gio/gtask.c b/gio/gtask.c
index a767e1909..2c788367a 100644
--- a/gio/gtask.c
+++ b/gio/gtask.c
@@ -58,6 +58,10 @@
* use g_task_propagate_pointer() or the like to extract the
* return value.
*
+ * Using #GTask requires the thread-default #GMainContext from when the
+ * #GTask was constructed to be running at least until the task has completed
+ * and its data has been freed.
+ *
* Here is an example for using GTask as a GAsyncResult:
* |[<!-- language="C" -->
* typedef struct {