Mercurial > ~mikael > mcabber > hg
comparison mcabber/src/otr.c @ 1495:6f5754f86fbb
Fix JID case issue with OTR, v2 (franky)
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Tue, 24 Jun 2008 19:17:26 +0200 |
parents | a8b924b5474c |
children | 24ff212a1c54 |
comparison
equal
deleted
inserted
replaced
1494:ff0ed873ec19 | 1495:6f5754f86fbb |
---|---|
195 } | 195 } |
196 | 196 |
197 static ConnContext * otr_get_context(const char *buddy) | 197 static ConnContext * otr_get_context(const char *buddy) |
198 { | 198 { |
199 int null = 0; | 199 int null = 0; |
200 return otrl_context_find(userstate, buddy, account, "jabber", 1, &null, | 200 ConnContext * ctx; |
201 NULL, NULL); | 201 char * lowcasebuddy = g_strdup(buddy); |
202 | |
203 mc_strtolower(lowcasebuddy); | |
204 ctx = otrl_context_find(userstate, lowcasebuddy, account, "jabber", 1, &null, | |
205 NULL, NULL); | |
206 g_free(lowcasebuddy); | |
207 return ctx; | |
202 } | 208 } |
203 | 209 |
204 static void otr_message_disconnect(ConnContext *ctx) | 210 static void otr_message_disconnect(ConnContext *ctx) |
205 { | 211 { |
206 if (ctx->msgstate == OTRL_MSGSTATE_ENCRYPTED) | 212 if (ctx->msgstate == OTRL_MSGSTATE_ENCRYPTED) |