diff options
author | Sulabh Mahajan <sulabh@pidgin.im> | 2008-09-27 15:30:10 +0000 |
---|---|---|
committer | Sulabh Mahajan <sulabh@pidgin.im> | 2008-09-27 15:30:10 +0000 |
commit | f2dee8b84f85847584c9b2b1bb43f139f707c4f7 (patch) | |
tree | 46c87345a61769b0023a192c9faf08ed5439a045 | |
parent | 0628aac8e17dfba175b31f99520511d362599772 (diff) | |
download | pidgin-f2dee8b84f85847584c9b2b1bb43f139f707c4f7.tar.gz |
dont initiate p2p connection with a peer, while we are waiting for another peer to conenct to us
-rw-r--r-- | libpurple/protocols/yahoo/yahoo.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libpurple/protocols/yahoo/yahoo.c b/libpurple/protocols/yahoo/yahoo.c index e1f95ac323..1b96973ac2 100644 --- a/libpurple/protocols/yahoo/yahoo.c +++ b/libpurple/protocols/yahoo/yahoo.c @@ -2638,6 +2638,10 @@ void yahoo_send_p2p_pkt(PurpleConnection *gc, const char *who, int val_13) f = yahoo_friend_find(gc, who); account = purple_connection_get_account(gc); + /* Do not send invitation if already listening for other connection */ + if(yd->yahoo_local_p2p_server_fd) + return; + /* One shouldn't try to connect to self */ if( strcmp(purple_normalize(account, purple_account_get_username(account)), who) == 0) return; |