Mercurial > pidgin.yaz
comparison libgaim/protocols/qq/group_find.c @ 14629:6b8bc59414f0
[gaim-migrate @ 17375]
Get rid of these useless checks.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Huetsch <markhuetsch> |
---|---|
date | Tue, 26 Sep 2006 22:54:24 +0000 |
parents | 8ff8f1c897b5 |
children | c039c920e11c |
comparison
equal
deleted
inserted
replaced
14628:58202142e9ad | 14629:6b8bc59414f0 |
---|---|
34 gboolean qq_group_find_internal_group_id_by_seq(GaimConnection *gc, guint16 seq, guint32 *internal_group_id) | 34 gboolean qq_group_find_internal_group_id_by_seq(GaimConnection *gc, guint16 seq, guint32 *internal_group_id) |
35 { | 35 { |
36 GList *list; | 36 GList *list; |
37 qq_data *qd; | 37 qq_data *qd; |
38 group_packet *p; | 38 group_packet *p; |
39 | |
40 g_return_val_if_fail(gc != NULL && gc->proto_data != NULL, FALSE); | |
41 | 39 |
42 if (internal_group_id == NULL) | 40 if (internal_group_id == NULL) |
43 return FALSE; | 41 return FALSE; |
44 qd = (qq_data *) gc->proto_data; | 42 qd = (qq_data *) gc->proto_data; |
45 | 43 |
98 | 96 |
99 qq_buddy *qq_group_find_or_add_member(GaimConnection *gc, qq_group *group, guint32 member_uid) | 97 qq_buddy *qq_group_find_or_add_member(GaimConnection *gc, qq_group *group, guint32 member_uid) |
100 { | 98 { |
101 qq_buddy *member, *q_bud; | 99 qq_buddy *member, *q_bud; |
102 GaimBuddy *buddy; | 100 GaimBuddy *buddy; |
103 g_return_val_if_fail(gc != NULL && group != NULL && member_uid > 0, NULL); | 101 g_return_val_if_fail(group != NULL && member_uid > 0, NULL); |
104 | 102 |
105 member = qq_group_find_member_by_uid(group, member_uid); | 103 member = qq_group_find_member_by_uid(group, member_uid); |
106 if (member == NULL) { /* first appear during my session */ | 104 if (member == NULL) { /* first appear during my session */ |
107 member = g_new0(qq_buddy, 1); | 105 member = g_new0(qq_buddy, 1); |
108 member->uid = member_uid; | 106 member->uid = member_uid; |
126 GaimConversation *conv; | 124 GaimConversation *conv; |
127 qq_data *qd; | 125 qq_data *qd; |
128 qq_group *group; | 126 qq_group *group; |
129 GList *list; | 127 GList *list; |
130 | 128 |
131 g_return_val_if_fail(gc != NULL && gc->proto_data != NULL, NULL); | |
132 qd = (qq_data *) gc->proto_data; | 129 qd = (qq_data *) gc->proto_data; |
133 | 130 |
134 conv = gaim_find_chat(gc, channel); | 131 conv = gaim_find_chat(gc, channel); |
135 g_return_val_if_fail(conv != NULL, NULL); | 132 g_return_val_if_fail(conv != NULL, NULL); |
136 | 133 |
151 { | 148 { |
152 GList *list; | 149 GList *list; |
153 qq_group *group; | 150 qq_group *group; |
154 qq_data *qd; | 151 qq_data *qd; |
155 | 152 |
156 g_return_val_if_fail(gc != NULL && gc->proto_data != NULL, NULL); | |
157 qd = (qq_data *) gc->proto_data; | 153 qd = (qq_data *) gc->proto_data; |
158 | 154 |
159 if (qd->groups == NULL || id <= 0) | 155 if (qd->groups == NULL || id <= 0) |
160 return NULL; | 156 return NULL; |
161 | 157 |