From 54f2f55f983f4b6bb8a58772bbd1137580e3307f Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Mon, 4 Jun 2007 12:45:33 +0100 Subject: Now anonymous rooms should really work. This makes sure the self-join will actually be recognized properly. This is running on my work machine for a few days already. --- protocols/jabber/conference.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'protocols/jabber/conference.c') diff --git a/protocols/jabber/conference.c b/protocols/jabber/conference.c index dde2b8b5..a97590ba 100644 --- a/protocols/jabber/conference.c +++ b/protocols/jabber/conference.c @@ -144,10 +144,14 @@ void jabber_chat_pkt_presence( struct im_connection *ic, struct jabber_buddy *bu /* Make up some other handle, if necessary. */ if( bud->ext_jid == NULL ) { - /* Don't want the nick to be at the end, so let's - think of some slightly different notation to use - for anonymous groupchat participants in BitlBee. */ - bud->ext_jid = g_strdup_printf( "%s=%s", bud->resource, bud->bare_jid ); + if( bud == jc->me ) + bud->ext_jid = g_strdup( ic->acc->user ); + else + /* Don't want the nick to be at the end, so let's + think of some slightly different notation to use + for anonymous groupchat participants in BitlBee. */ + bud->ext_jid = g_strdup_printf( "%s=%s", bud->resource, bud->bare_jid ); + bud->flags |= JBFLAG_IS_ANONYMOUS; } -- cgit v1.2.3