summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--examples/test-raw.c2
-rw-r--r--examples/test-xml.c2
-rw-r--r--tests/oauth-async.c26
-rw-r--r--tests/threaded.c2
4 files changed, 17 insertions, 15 deletions
diff --git a/examples/test-raw.c b/examples/test-raw.c
index 7ad651c..fa6702e 100644
--- a/examples/test-raw.c
+++ b/examples/test-raw.c
@@ -25,7 +25,7 @@
static void
proxy_call_async_cb (RestProxyCall *call,
- GError *error,
+ const GError *error,
GObject *weak_object,
gpointer userdata)
{
diff --git a/examples/test-xml.c b/examples/test-xml.c
index c7ec853..f8460db 100644
--- a/examples/test-xml.c
+++ b/examples/test-xml.c
@@ -84,7 +84,7 @@ _rest_xml_node_output (RestXmlNode *node, gint depth)
static void
proxy_call_raw_async_cb (RestProxyCall *call,
- GError *error,
+ const GError *error,
GObject *weak_object,
gpointer userdata)
{
diff --git a/tests/oauth-async.c b/tests/oauth-async.c
index 330d2f8..51c8546 100644
--- a/tests/oauth-async.c
+++ b/tests/oauth-async.c
@@ -63,13 +63,13 @@ make_calls (OAuthProxy *oproxy)
}
static void
-access_token_cb (OAuthProxy *proxy,
- GError *error,
- GObject *weak_object,
- gpointer user_data)
+access_token_cb (OAuthProxy *proxy,
+ const GError *error,
+ GObject *weak_object,
+ gpointer user_data)
{
OAuthProxyPrivate *priv = PROXY_GET_PRIVATE (proxy);
- g_assert_no_error (error);
+ g_assert_no_error ((GError *)error);
g_assert_cmpstr (priv->token, ==, "accesskey");
g_assert_cmpstr (priv->token_secret, ==, "accesssecret");
@@ -78,21 +78,23 @@ access_token_cb (OAuthProxy *proxy,
}
static void
-request_token_cb (OAuthProxy *proxy,
- GError *error,
- GObject *weak_object,
- gpointer user_data)
+request_token_cb (OAuthProxy *proxy,
+ const GError *error,
+ GObject *weak_object,
+ gpointer user_data)
{
OAuthProxyPrivate *priv = PROXY_GET_PRIVATE (proxy);
- g_assert_no_error (error);
+ GError *err = NULL;
+
+ g_assert_no_error ((GError *)error);
g_assert_cmpstr (priv->token, ==, "requestkey");
g_assert_cmpstr (priv->token_secret, ==, "requestsecret");
/* Second stage authentication, this gets an access token */
oauth_proxy_access_token_async (proxy, "access_token.php", NULL,
- access_token_cb, NULL, NULL, &error);
- g_assert_no_error (error);
+ access_token_cb, NULL, NULL, &err);
+ g_assert_no_error (err);
}
int
diff --git a/tests/threaded.c b/tests/threaded.c
index ea086e4..1bc050e 100644
--- a/tests/threaded.c
+++ b/tests/threaded.c
@@ -90,7 +90,7 @@ main (int argc, char **argv)
server = soup_server_new (NULL);
soup_server_add_handler (server, NULL, server_callback, NULL, NULL);
- g_thread_create (soup_server_run, server, FALSE, NULL);
+ g_thread_create ((GThreadFunc)soup_server_run, server, FALSE, NULL);
url = g_strdup_printf ("http://127.0.0.1:%d/", soup_server_get_port (server));