[libsoup] misc: Remove unused functions
- From: Patrick Griffis <pgriffis src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libsoup] misc: Remove unused functions
- Date: Fri, 13 Nov 2020 18:56:54 +0000 (UTC)
commit 5a61da0b51c019296525f06038c5ccc039dfe210
Author: Patrick Griffis <pgriffis igalia com>
Date: Fri Nov 13 12:55:33 2020 -0600
misc: Remove unused functions
libsoup/soup-client-input-stream.c | 7 +++--
libsoup/soup-misc.c | 55 --------------------------------------
libsoup/soup-misc.h | 8 ------
3 files changed, 5 insertions(+), 65 deletions(-)
---
diff --git a/libsoup/soup-client-input-stream.c b/libsoup/soup-client-input-stream.c
index 1d698fa6..d3a75467 100644
--- a/libsoup/soup-client-input-stream.c
+++ b/libsoup/soup-client-input-stream.c
@@ -181,8 +181,11 @@ close_async_ready (SoupMessage *msg, gpointer user_data)
* waiting one extra cycle after run_until_finish() returns.
* Ugh. FIXME later when it's easier to do.
*/
- soup_add_idle (g_main_context_get_thread_default (),
- idle_finish_close, task);
+ GSource *source = g_idle_source_new ();
+ g_source_set_callback (source, idle_finish_close, task, NULL);
+ g_source_attach (source, g_main_context_get_thread_default ());
+ g_source_unref (source);
+
return FALSE;
}
diff --git a/libsoup/soup-misc.c b/libsoup/soup-misc.c
index 34bbf241..fb58ad30 100644
--- a/libsoup/soup-misc.c
+++ b/libsoup/soup-misc.c
@@ -53,61 +53,6 @@ soup_str_case_equal (gconstpointer v1,
return g_ascii_strcasecmp (string1, string2) == 0;
}
-/**
- * soup_add_io_watch: (skip)
- * @async_context: (allow-none): the #GMainContext to dispatch the I/O
- * watch in, or %NULL for the default context
- * @chan: the #GIOChannel to watch
- * @condition: the condition to watch for
- * @function: the callback to invoke when @condition occurs
- * @data: user data to pass to @function
- *
- * Adds an I/O watch as with g_io_add_watch(), but using the given
- * @async_context.
- *
- * Return value: a #GSource, which can be removed from @async_context
- * with g_source_destroy().
- **/
-GSource *
-soup_add_io_watch (GMainContext *async_context,
- GIOChannel *chan, GIOCondition condition,
- GIOFunc function, gpointer data)
-{
- GSource *watch = g_io_create_watch (chan, condition);
- g_source_set_callback (watch, (GSourceFunc) function, data, NULL);
- g_source_attach (watch, async_context);
- g_source_unref (watch);
- return watch;
-}
-
-/**
- * soup_add_idle: (skip)
- * @async_context: (allow-none): the #GMainContext to dispatch the I/O
- * watch in, or %NULL for the default context
- * @function: the callback to invoke at idle time
- * @data: user data to pass to @function
- *
- * Adds an idle event as with g_idle_add(), but using the given
- * @async_context.
- *
- * If you want @function to run "right away", use
- * soup_add_completion(), since that sets a higher priority on the
- * #GSource than soup_add_idle() does.
- *
- * Return value: a #GSource, which can be removed from @async_context
- * with g_source_destroy().
- **/
-GSource *
-soup_add_idle (GMainContext *async_context,
- GSourceFunc function, gpointer data)
-{
- GSource *source = g_idle_source_new ();
- g_source_set_callback (source, function, data, NULL);
- g_source_attach (source, async_context);
- g_source_unref (source);
- return source;
-}
-
GSource *
soup_add_completion_reffed (GMainContext *async_context,
GSourceFunc function,
diff --git a/libsoup/soup-misc.h b/libsoup/soup-misc.h
index 770ecf54..1efdd6d0 100644
--- a/libsoup/soup-misc.h
+++ b/libsoup/soup-misc.h
@@ -13,14 +13,6 @@
G_BEGIN_DECLS
/* Non-default-GMainContext operations */
-GSource *soup_add_io_watch (GMainContext *async_context,
- GIOChannel *chan,
- GIOCondition condition,
- GIOFunc function,
- gpointer data);
-GSource *soup_add_idle (GMainContext *async_context,
- GSourceFunc function,
- gpointer data);
GSource *soup_add_completion (GMainContext *async_context,
GSourceFunc function,
gpointer data);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]