Changeset fa9478e
- Timestamp:
- 2013-08-02T15:30:11Z (11 years ago)
- Branches:
- master
- Children:
- 37ed402
- Parents:
- 22ec21d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
otr.c
r22ec21d rfa9478e 665 665 int op_max_message_size(void *opdata, ConnContext *context) 666 666 { 667 /* libotr 4.0.0 has a bug where it doesn't set opdata */668 if(!opdata) {669 /* crude fallback */670 return 800;671 }672 673 667 struct im_connection *ic = 674 668 check_imc(opdata, context->accountname, context->protocol); … … 1370 1364 struct im_connection *ic = (struct im_connection *)opdata; 1371 1365 1366 /* libotr 4.0.0 has a bug where it doesn't set opdata, so we catch 1367 * that and try to find the desired connection in the global list. */ 1368 if(!ic) { 1369 GSList *l; 1370 for(l=get_connections(); l; l=l->next) { 1371 ic = l->data; 1372 if(strcmp(accountname, ic->acc->user) == 0 && 1373 strcmp(protocol, ic->acc->prpl->name) == 0) 1374 break; 1375 } 1376 assert(l != NULL); /* a match should always be found */ 1377 } 1378 1372 1379 if (strcmp(accountname, ic->acc->user) != 0) { 1373 1380 log_message(LOGLVL_WARNING,
Note: See TracChangeset
for help on using the changeset viewer.