aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy/empathy-utils.c
diff options
context:
space:
mode:
authorXavier Claessens <xclaesse@gmail.com>2009-04-21 07:14:34 +0800
committerXavier Claessens <xclaesse@gmail.com>2009-04-22 18:21:15 +0800
commitaa098bf904f8e85fa6aa44ffea99e1e027775d26 (patch)
treed5e0beedba9bac8df9c142609c89f3abba7f67ec /libempathy/empathy-utils.c
parentf9911a59c6cb1609535e105b6b31913acf8f0e30 (diff)
downloadgsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.tar
gsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.tar.gz
gsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.tar.bz2
gsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.tar.lz
gsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.tar.xz
gsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.tar.zst
gsoc2013-empathy-aa098bf904f8e85fa6aa44ffea99e1e027775d26.zip
Replace empathy_connection_get_protocol by tp_connection_parse_object_path
Diffstat (limited to 'libempathy/empathy-utils.c')
-rw-r--r--libempathy/empathy-utils.c28
1 files changed, 0 insertions, 28 deletions
diff --git a/libempathy/empathy-utils.c b/libempathy/empathy-utils.c
index 8b140ad43..210c35048 100644
--- a/libempathy/empathy-utils.c
+++ b/libempathy/empathy-utils.c
@@ -379,31 +379,3 @@ empathy_check_available_state (void)
return TRUE;
}
-gchar *
-empathy_connection_get_protocol (TpConnection *connection,
- gchar **ret_cmname)
-{
- const gchar *object_path;
- const gchar *cmname;
- const gchar *proto;
- const gchar *account;
- gchar *ret;
-
- g_return_val_if_fail (TP_IS_CONNECTION (connection), NULL);
-
- /* Object path is in the form:
- * /org/freedesktop/Telepathy/Connection/cmname/proto/account */
- object_path = tp_proxy_get_object_path (TP_PROXY (connection));
- cmname = object_path + strlen ("/org/freedesktop/Telepathy/Connection/");
- proto = strstr (cmname, "/") + 1;
- account = strstr (proto, "/") + 1;
-
- if (ret_cmname) {
- *ret_cmname = g_strndup (cmname, proto - cmname - 1);
- g_strdelimit (*ret_cmname, "_", '-');
- }
-
- ret = g_strndup (proto, account - proto - 1);
- return g_strdelimit (ret, "_", '-');
-}
-