/pidgin/main: 909e73523124: libpurple: fix incorrect check for p...
Daniel Atallah
datallah at pidgin.im
Sun Feb 24 21:23:44 EST 2013
Changeset: 909e73523124f1890325add29e6e85612f6ebf34
Author: Daniel Atallah <datallah at pidgin.im>
Date: 2013-02-24 21:23 -0500
Branch: release-2.x.y
URL: https://hg.pidgin.im/pidgin/main/rev/909e73523124
Description:
libpurple: fix incorrect check for password being optional (it was always being
considered optional)
* CID 732002
diffstat:
libpurple/account.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (30 lines):
diff --git a/libpurple/account.c b/libpurple/account.c
--- a/libpurple/account.c
+++ b/libpurple/account.c
@@ -1550,7 +1550,7 @@ purple_account_request_change_password(P
field = purple_request_field_string_new("password", _("Original password"),
NULL, FALSE);
purple_request_field_string_set_masked(field, TRUE);
- if (!(prpl_info && (prpl_info->options | OPT_PROTO_PASSWORD_OPTIONAL)))
+ if (!prpl_info || !(prpl_info->options & OPT_PROTO_PASSWORD_OPTIONAL))
purple_request_field_set_required(field, TRUE);
purple_request_field_group_add_field(group, field);
@@ -1558,7 +1558,7 @@ purple_account_request_change_password(P
_("New password"),
NULL, FALSE);
purple_request_field_string_set_masked(field, TRUE);
- if (!(prpl_info && (prpl_info->options | OPT_PROTO_PASSWORD_OPTIONAL)))
+ if (!prpl_info || !(prpl_info->options & OPT_PROTO_PASSWORD_OPTIONAL))
purple_request_field_set_required(field, TRUE);
purple_request_field_group_add_field(group, field);
@@ -1566,7 +1566,7 @@ purple_account_request_change_password(P
_("New password (again)"),
NULL, FALSE);
purple_request_field_string_set_masked(field, TRUE);
- if (!(prpl_info && (prpl_info->options | OPT_PROTO_PASSWORD_OPTIONAL)))
+ if (!prpl_info || !(prpl_info->options & OPT_PROTO_PASSWORD_OPTIONAL))
purple_request_field_set_required(field, TRUE);
purple_request_field_group_add_field(group, field);
More information about the Commits
mailing list