Mercurial > pidgin.yaz
comparison libpurple/protocols/silc/ft.c @ 22800:67a4c8c46f78
Cleanup allocations/frees to match and plug some leaks.
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Sat, 03 May 2008 07:13:58 +0000 |
parents | 2f35d56d2add |
children | f1437342cc0e |
comparison
equal
deleted
inserted
replaced
22799:fc1e708ddf92 | 22800:67a4c8c46f78 |
---|---|
422 g_snprintf(tmp, sizeof(tmp), | 422 g_snprintf(tmp, sizeof(tmp), |
423 _("User %s is not present in the network"), | 423 _("User %s is not present in the network"), |
424 (const char *)context); | 424 (const char *)context); |
425 purple_notify_error(gc, _("Secure File Transfer"), | 425 purple_notify_error(gc, _("Secure File Transfer"), |
426 _("Cannot send file"), tmp); | 426 _("Cannot send file"), tmp); |
427 silc_free(context); | 427 g_free(context); |
428 return; | 428 return; |
429 } | 429 } |
430 | 430 |
431 silcpurple_ftp_send_file(client->application, (const char *)context, NULL); | 431 silcpurple_ftp_send_file(client->application, (const char *)context, NULL); |
432 silc_free(context); | 432 g_free(context); |
433 } | 433 } |
434 | 434 |
435 PurpleXfer *silcpurple_ftp_new_xfer(PurpleConnection *gc, const char *name) | 435 PurpleXfer *silcpurple_ftp_new_xfer(PurpleConnection *gc, const char *name) |
436 { | 436 { |
437 SilcPurple sg = gc->proto_data; | 437 SilcPurple sg = gc->proto_data; |
445 /* Find client entry */ | 445 /* Find client entry */ |
446 clients = silc_client_get_clients_local(client, conn, name, FALSE); | 446 clients = silc_client_get_clients_local(client, conn, name, FALSE); |
447 if (!clients) { | 447 if (!clients) { |
448 silc_client_get_clients(client, conn, name, NULL, | 448 silc_client_get_clients(client, conn, name, NULL, |
449 silcpurple_ftp_send_file_resolved, | 449 silcpurple_ftp_send_file_resolved, |
450 strdup(name)); | 450 g_strdup(name)); |
451 return NULL; | 451 return NULL; |
452 } | 452 } |
453 silc_dlist_start(clients); | 453 silc_dlist_start(clients); |
454 | 454 |
455 xfer = silc_calloc(1, sizeof(*xfer)); | 455 xfer = silc_calloc(1, sizeof(*xfer)); |