Changes in protocols/nogaim.c [66aefeb:098a75b]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/nogaim.c
r66aefeb r098a75b 132 132 extern void twitter_initmodule(); 133 133 extern void purple_initmodule(); 134 extern void rpc_initmodule();135 134 136 135 #ifdef WITH_MSN … … 156 155 #ifdef WITH_PURPLE 157 156 purple_initmodule(); 158 #endif159 160 #ifdef WITH_RPC161 rpc_initmodule();162 157 #endif 163 158 … … 503 498 }; 504 499 505 static void imcb_ask_ auth_cb_no(void *data)500 static void imcb_ask_cb_free(void *data) 506 501 { 507 502 struct imcb_ask_cb_data *cbd = data; 508 509 cbd->ic->acc->prpl->auth_deny(cbd->ic, cbd->handle);510 503 511 504 g_free(cbd->handle); … … 513 506 } 514 507 508 static void imcb_ask_auth_cb_no(void *data) 509 { 510 struct imcb_ask_cb_data *cbd = data; 511 512 cbd->ic->acc->prpl->auth_deny(cbd->ic, cbd->handle); 513 514 imcb_ask_cb_free(cbd); 515 } 516 515 517 static void imcb_ask_auth_cb_yes(void *data) 516 518 { … … 519 521 cbd->ic->acc->prpl->auth_allow(cbd->ic, cbd->handle); 520 522 521 g_free(cbd->handle); 522 g_free(cbd); 523 imcb_ask_cb_free(cbd); 523 524 } 524 525 … … 540 541 data->handle = g_strdup(handle); 541 542 query_add((irc_t *) ic->bee->ui_data, ic, s, 542 imcb_ask_auth_cb_yes, imcb_ask_auth_cb_no, g_free, data); 543 } 544 545 546 static void imcb_ask_add_cb_no(void *data) 547 { 548 g_free(((struct imcb_ask_cb_data*) data)->handle); 549 g_free(data); 543 imcb_ask_auth_cb_yes, imcb_ask_auth_cb_no, imcb_ask_cb_free, data); 544 545 g_free(s); 550 546 } 551 547 … … 556 552 cbd->ic->acc->prpl->add_buddy(cbd->ic, cbd->handle, NULL); 557 553 558 imcb_ask_ add_cb_no(data);554 imcb_ask_cb_free(data); 559 555 } 560 556 561 557 void imcb_ask_add(struct im_connection *ic, const char *handle, const char *realname) 562 558 { 563 struct imcb_ask_cb_data *data = g_new0(struct imcb_ask_cb_data, 1);559 struct imcb_ask_cb_data *data; 564 560 char *s; 565 561 … … 569 565 } 570 566 567 data = g_new0(struct imcb_ask_cb_data, 1); 568 571 569 s = g_strdup_printf("The user %s is not in your buddy list yet. Do you want to add him/her now?", handle); 572 570 … … 574 572 data->handle = g_strdup(handle); 575 573 query_add((irc_t *) ic->bee->ui_data, ic, s, 576 imcb_ask_add_cb_yes, imcb_ask_add_cb_no, g_free, data); 574 imcb_ask_add_cb_yes, imcb_ask_cb_free, imcb_ask_cb_free, data); 575 576 g_free(s); 577 577 } 578 578
Note: See TracChangeset
for help on using the changeset viewer.