Mercurial > pidgin
comparison libpurple/ft.c @ 17992:5e34cd288a98
merge of 'bdd3cb040100fe925456b862d03cc6c5a61648ef'
and 'd4717c30b427fc205d5e8026f0d4305f7cd53f5c'
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Sat, 02 Jun 2007 06:43:53 +0000 |
parents | e62095e99db0 |
children | 57d350900136 bb30030a22b6 |
comparison
equal
deleted
inserted
replaced
17431:79ecaab86f91 | 17992:5e34cd288a98 |
---|---|
21 * along with this program; if not, write to the Free Software | 21 * along with this program; if not, write to the Free Software |
22 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 22 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
23 * | 23 * |
24 */ | 24 */ |
25 #include "internal.h" | 25 #include "internal.h" |
26 #include "dbus-maybe.h" | |
26 #include "ft.h" | 27 #include "ft.h" |
27 #include "network.h" | 28 #include "network.h" |
28 #include "notify.h" | 29 #include "notify.h" |
29 #include "prefs.h" | 30 #include "prefs.h" |
30 #include "proxy.h" | 31 #include "proxy.h" |
54 g_return_val_if_fail(type != PURPLE_XFER_UNKNOWN, NULL); | 55 g_return_val_if_fail(type != PURPLE_XFER_UNKNOWN, NULL); |
55 g_return_val_if_fail(account != NULL, NULL); | 56 g_return_val_if_fail(account != NULL, NULL); |
56 g_return_val_if_fail(who != NULL, NULL); | 57 g_return_val_if_fail(who != NULL, NULL); |
57 | 58 |
58 xfer = g_new0(PurpleXfer, 1); | 59 xfer = g_new0(PurpleXfer, 1); |
60 PURPLE_DBUS_REGISTER_POINTER(xfer, PurpleXfer); | |
59 | 61 |
60 xfer->ref = 1; | 62 xfer->ref = 1; |
61 xfer->type = type; | 63 xfer->type = type; |
62 xfer->account = account; | 64 xfer->account = account; |
63 xfer->who = g_strdup(who); | 65 xfer->who = g_strdup(who); |
95 g_free(xfer->who); | 97 g_free(xfer->who); |
96 g_free(xfer->filename); | 98 g_free(xfer->filename); |
97 g_free(xfer->remote_ip); | 99 g_free(xfer->remote_ip); |
98 g_free(xfer->local_filename); | 100 g_free(xfer->local_filename); |
99 | 101 |
102 PURPLE_DBUS_UNREGISTER_POINTER(xfer); | |
100 g_free(xfer); | 103 g_free(xfer); |
101 xfers = g_list_remove(xfers, xfer); | 104 xfers = g_list_remove(xfers, xfer); |
102 } | 105 } |
103 | 106 |
104 void | 107 void |
547 purple_xfer_get_account(const PurpleXfer *xfer) | 550 purple_xfer_get_account(const PurpleXfer *xfer) |
548 { | 551 { |
549 g_return_val_if_fail(xfer != NULL, NULL); | 552 g_return_val_if_fail(xfer != NULL, NULL); |
550 | 553 |
551 return xfer->account; | 554 return xfer->account; |
555 } | |
556 | |
557 const char * | |
558 purple_xfer_get_remote_user(const PurpleXfer *xfer) | |
559 { | |
560 g_return_val_if_fail(xfer != NULL, NULL); | |
561 return xfer->who; | |
552 } | 562 } |
553 | 563 |
554 PurpleXferStatusType | 564 PurpleXferStatusType |
555 purple_xfer_get_status(const PurpleXfer *xfer) | 565 purple_xfer_get_status(const PurpleXfer *xfer) |
556 { | 566 { |