[gvfs] afp: use g_strcmp0 instead of g_str_equal in g_slist_find_custom
- From: Christian Kellner <gicmo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gvfs] afp: use g_strcmp0 instead of g_str_equal in g_slist_find_custom
- Date: Thu, 25 Aug 2011 19:28:05 +0000 (UTC)
commit 7682cfeb26a5746eab1bbd16ef64fb06a47bba4b
Author: Carl-Anton Ingmarsson <ca ingmarsson gmail com>
Date: Mon Aug 1 23:24:05 2011 +0200
afp: use g_strcmp0 instead of g_str_equal in g_slist_find_custom
daemon/gvfsafpserver.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/daemon/gvfsafpserver.c b/daemon/gvfsafpserver.c
index acafb87..cf1c431 100644
--- a/daemon/gvfsafpserver.c
+++ b/daemon/gvfsafpserver.c
@@ -676,7 +676,7 @@ do_login (GVfsAfpServer *afp_serv,
GVfsAfpReply *reply;
AfpResultCode res_code;
- if (!g_slist_find_custom (afp_serv->uams, AFP_UAM_NO_USER, g_str_equal))
+ if (!g_slist_find_custom (afp_serv->uams, AFP_UAM_NO_USER, (GCompareFunc)g_strcmp0))
{
g_set_error (error, G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED,
_("AFP server %s doesn't support anonymous login"),
@@ -729,11 +729,11 @@ do_login (GVfsAfpServer *afp_serv,
#ifdef HAVE_GCRYPT
/* Diffie-Hellman 2 */
- if (g_slist_find_custom (afp_serv->uams, AFP_UAM_DHX2, g_str_equal))
+ if (g_slist_find_custom (afp_serv->uams, AFP_UAM_DHX2, (GCompareFunc)g_strcmp0))
return dhx2_login (afp_serv, username, password, cancellable, error);
/* Diffie-Hellman */
- if (g_slist_find_custom (afp_serv->uams, AFP_UAM_DHX, g_str_equal))
+ if (g_slist_find_custom (afp_serv->uams, AFP_UAM_DHX, (GCompareFunc)g_strcmp0))
return dhx_login (afp_serv, username, password, cancellable, error);
#endif
@@ -853,7 +853,7 @@ g_vfs_afp_server_login (GVfsAfpServer *afp_serv,
if (initial_user)
{
if (g_str_equal (initial_user, "anonymous") &&
- g_slist_find_custom (afp_serv->uams, AFP_UAM_NO_USER, g_str_equal))
+ g_slist_find_custom (afp_serv->uams, AFP_UAM_NO_USER, (GCompareFunc)g_strcmp0))
{
user = NULL;
password = NULL;
@@ -911,7 +911,7 @@ g_vfs_afp_server_login (GVfsAfpServer *afp_serv,
{
flags |= G_ASK_PASSWORD_NEED_USERNAME;
- if (g_slist_find_custom (afp_serv->uams, AFP_UAM_NO_USER, g_str_equal))
+ if (g_slist_find_custom (afp_serv->uams, AFP_UAM_NO_USER, (GCompareFunc)g_strcmp0))
flags |= G_ASK_PASSWORD_ANONYMOUS_SUPPORTED;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]