mIRC Home    About    Download    Register    News    Help

Print Thread
mIRC sends double MODE if opped #220215 07/04/10 06:22 PM
Joined: Feb 2006
Posts: 32
Daveoh Offline OP
Ameglian cow
OP Offline
Ameglian cow
Joined: Feb 2006
Posts: 32
I'm using mIRC on Win7 x64.
If you join a channel, mIRC sends a MODE request. If you are opped on that channel before receiving the MODE reply, it sends another one.
I have this happen to me when I join lots of channels which I have op in via a network bot, which then results in this:
Code:
-
* Flood protection: 4 message(s) in queue
-
* Flood protection: 14 message(s) in queue
-

Without flood protection I presume I would be disconnected from the server. This is not good. Does mIRC really need to send another MODE request?

Re: mIRC sends double MODE if opped [Re: Daveoh] #220222 07/04/10 08:52 PM
Joined: Dec 2002
Posts: 4,563
Khaled Offline
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 4,563
Yes, that is the correct behaviour. When you join a channel, a mode is sent to retrieve your mode settings. If you are then opped some time later, another mode needs to be sent to update your mode settings, since ops can have access to other settings.

Re: mIRC sends double MODE if opped [Re: Khaled] #220229 07/04/10 10:05 PM
Joined: Apr 2004
Posts: 841
Sat Offline
Hoopy frood
Offline
Hoopy frood
Joined: Apr 2004
Posts: 841
mIRC need not send another MODE request when the reply to the first one has not yet arrived, though..


Saturn, QuakeNet staff
Re: mIRC sends double MODE if opped [Re: Khaled] #220230 07/04/10 10:08 PM
Joined: Feb 2006
Posts: 32
Daveoh Offline OP
Ameglian cow
OP Offline
Ameglian cow
Joined: Feb 2006
Posts: 32
I thought I posted this in "Bug Reports," apparently not.

You say that it sends another "since ops can have access to other settings" however mine doesn't send another one if I am opped after receiving the initial MODE reply.

Re: mIRC sends double MODE if opped [Re: Daveoh] #220232 07/04/10 11:07 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
It would have to or you wouldn't see a key.


Invision Support
#Invision on irc.irchighway.net
Re: mIRC sends double MODE if opped [Re: Riamus2] #220233 07/04/10 11:19 PM
Joined: Feb 2006
Posts: 32
Daveoh Offline OP
Ameglian cow
OP Offline
Ameglian cow
Joined: Feb 2006
Posts: 32
On chans without a key, then.

Re: mIRC sends double MODE if opped [Re: Daveoh] #220234 07/04/10 11:29 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
There are other modes as well that aren't available except for ops. That was just an example. As Khaled said, you need both. If you're having issues with it, don't join so many channels all at once.


Invision Support
#Invision on irc.irchighway.net
Re: mIRC sends double MODE if opped [Re: Daveoh] #220237 08/04/10 08:11 AM
Joined: Dec 2002
Posts: 4,563
Khaled Offline
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 4,563
After looking through my code: mIRC may or may not send a mode when you are opped depending on a combination of the IRC network you are on, the type of channel, the type of op, and whether you have received a reply to a previous mode.

mIRC tracks how many channel modes are sent/received (this is the type of "state" that I would rather avoid tracking, since servers can sometimes send events like this without mIRC making a request, which results in internal tracking being thrown off leading to incorrect behaviors) and there is a check that prevents a second mode from being sent in this specific situation (which is not surprising since this issue has been commented on over the years many times), however the check has been commented out with a note that it caused problems on some networks. So it looks like it was implemented and then later removed.

My guess is that I could have made it behave that way only on specific networks, however the situation was not clear and I decided to err on the side of caution and disabled it completely.

Last edited by Khaled; 08/04/10 09:54 AM.
Re: mIRC sends double MODE if opped [Re: Khaled] #220246 08/04/10 04:38 PM
Joined: Dec 2002
Posts: 339
D
drum Offline
Fjord artisan
Offline
Fjord artisan
D
Joined: Dec 2002
Posts: 339
I think the current behavior is fine.

If there needs to be a change, my personal recommendation would be to delay the initial MODE request by 1-2 seconds in case you get opped within that time frame.

How do other popular IRC clients handle this?