Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Leaving XMPPRoom

Im developing an app that can log in the user in 2 xmpprooms, but only 2 at the same time, so if he wants to connect to another one I have to disconnect him from the previous and connect to the next one. Whith this code:

This is how I leave the room:

[[xmppRoom] leaveRoom]; 
[[xmppRoom] deactivate];
[[xmppRoom] removeDelegate:self];

And this is how I join the room:

[xmppRoom activate:[self xmppStream]];                
[xmppRoom joinRoom];

The funky behaviour is that if the room has more than 10 users it crashes without errors but if I enable NSZombies I see that the pointer is in the method [XMPPRoom isJoined], in this line:

dispatch_sync(moduleQueue, ^{
   result = _isJoined;
});

Any ideas?

like image 553
subharb Avatar asked Mar 19 '26 17:03

subharb


1 Answers

You didn't provide alot of information to work with, but your problem might be fixed by looking into this article that explains max users and how it handles max users. Good documentation by the way, I strongly recommend you check this out. And if you have any future xmpp problems, check this website first.

like image 178
Gabriel Avatar answered Mar 22 '26 06:03

Gabriel



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!