Mercurial > pidgin
comparison src/protocols/jabber/si.c @ 12935:d9c53c5f5912
[gaim-migrate @ 15288]
Fix a bug noted in SF Patch #1293248. We're building an invalid Jabber ID such as: user@server.tld/Resource/Resource
committer: Tailor Script <tailor@pidgin.im>
author | Richard Laager <rlaager@wiktel.com> |
---|---|
date | Thu, 19 Jan 2006 03:43:30 +0000 |
parents | 8e3b85fe4a55 |
children | 0f3122ce84db |
comparison
equal
deleted
inserted
replaced
12934:c6a202e5823b | 12935:d9c53c5f5912 |
---|---|
636 if(!jb) | 636 if(!jb) |
637 return; | 637 return; |
638 | 638 |
639 /* XXX: for now, send to the first resource available */ | 639 /* XXX: for now, send to the first resource available */ |
640 if(g_list_length(jb->resources) >= 1) { | 640 if(g_list_length(jb->resources) >= 1) { |
641 char **who_v = g_strsplit(xfer->who, "/"); | |
641 char *who; | 642 char *who; |
643 | |
642 jbr = jabber_buddy_find_resource(jb, NULL); | 644 jbr = jabber_buddy_find_resource(jb, NULL); |
643 who = g_strdup_printf("%s/%s", xfer->who, jbr->name); | 645 who = g_strdup_printf("%s/%s", who_v[0], jbr->name); |
646 g_strfreev(who_v); | |
644 g_free(xfer->who); | 647 g_free(xfer->who); |
645 xfer->who = who; | 648 xfer->who = who; |
646 jabber_disco_info_do(jsx->js, who, | 649 jabber_disco_info_do(jsx->js, who, |
647 jabber_si_xfer_send_disco_cb, xfer); | 650 jabber_si_xfer_send_disco_cb, xfer); |
648 } else { | 651 } else { |