comparison libpurple/protocols/yahoo/yahoo_filexfer.c @ 26145:abf830f6cd43

When sending a file, if there isn't a p2p connection, try establishing it. one.
author Sulabh Mahajan <sulabh@soc.pidgin.im>
date Fri, 22 Aug 2008 15:00:16 +0000
parents 9a5da524fba9
children eb21f65728c0
comparison
equal deleted inserted replaced
26144:0dd4629e75ee 26145:abf830f6cd43
1045 struct yahoo_data *yd = gc->proto_data; 1045 struct yahoo_data *yd = gc->proto_data;
1046 PurpleXfer *xfer = yahoo_new_xfer(gc, who); 1046 PurpleXfer *xfer = yahoo_new_xfer(gc, who);
1047 1047
1048 g_return_if_fail(xfer != NULL); 1048 g_return_if_fail(xfer != NULL);
1049 1049
1050 /* if we don't have a p2p connection, try establishing it now */
1051 if( !g_hash_table_lookup(yd->peers, who) )
1052 yahoo_send_p2p_pkt(gc, who, 0);
1053
1050 xfer_data = xfer->data; 1054 xfer_data = xfer->data;
1051 xfer_data->status_15 = STARTED; 1055 xfer_data->status_15 = STARTED;
1052 purple_xfer_set_init_fnc(xfer, yahoo_xfer_init_15); 1056 purple_xfer_set_init_fnc(xfer, yahoo_xfer_init_15);
1053 xfer_data->version = 15; 1057 xfer_data->version = 15;
1054 xfer_data->xfer_peer_idstring = yahoo_xfer_new_xfer_id(); 1058 xfer_data->xfer_peer_idstring = yahoo_xfer_new_xfer_id();