View Issue Details

IDProjectCategoryView StatusLast Update
0004326unrealmodule apipublic2015-06-01 04:05
Reporterhyperi0n Assigned Totmcarthur  
PrioritynormalSeverityminorReproducibilityhave not tried
Status resolvedResolutionfixed 
PlatformArchlinux x86_64OSLinux OS Version3.16.1-1
Product Version3.4-alpha1 
Summary0004326: Error when reloading module delayjoin
Descriptionmode +D works fine but when i unload/reload the delayjoin module,
i get an "Unknown mode character D" when trying /mode #channel +D
/module commands tells me that *** delayjoin - v0.0.1 (delayed join (+D,+d)) is here.
Steps To Reproduce- comment loadmodule "modules/chanmodes/delayjoin"; /* +D */ in modules.conf
- rehash
- uncomment the same line
- rehash
- try /mode #channel +D
TagsNo tags attached.
3rd party modules

Activities

tmcarthur

2014-08-18 20:34

reporter   ~0018225

Having a look thanks

hyperi0n

2014-08-19 13:25

reporter   ~0018226

I can reproduce the same issue with other modes (tested with +G +z)

Stealth

2014-08-19 16:28

reporter   ~0018227

I know it would be time consuming, but would someone be willing to do this with all modules (commands AND modes)? If it's happening in a handful of modules it will likely be found in other modules. We should build a list of modules that fail to unload and reload properly.

Stealth

2014-08-19 16:31

reporter   ~0018228

@tmcarthur should we make separate bug reports for every module with this issue, or do you think fixing one would make it super easy to fix them all?

tmcarthur

2014-08-19 16:48

reporter   ~0018229

This may be something we need to do on module by module basis, but having one master tracking bug is probably easier/better - if someone gets a chance to test and make a list I would suggest just add it as a comment to this bug. If no one does, I can look at testing it myself as I fix this one.

hyperi0n

2014-08-19 21:46

reporter   ~0018230

Ok here are the test concerning the others modules :

-commands : not affected (tested only whois and cloak...)
-user modes not affected (test on +G and +T, only modules available today)
-chan modes :
  Z => set by server
  cCSPGDKVOATRNQMz => bug reproductible
  Kj => MOD_OPT_PERM (looks like they are designed so that we cant unload them)
  f => crash on unload (filling an bug report right now)

tmcarthur

2014-08-19 22:17

reporter   ~0018232

Having a look now - thanks for testing this and getting us details!

hyperi0n

2014-08-21 22:59

reporter   ~0018233

Adding this Line 190 in extcmode.c seems to fix it for all modes:

Channelmode_Table[i].unloaded = 0;

Not sure of the consequences but so far it's ok for me.

tmcarthur

2014-08-23 06:47

reporter   ~0018237

Thanks for the report!

The reason that change works is that it immediately marks a channel mode as unloaded after it is added, the problem with this is it is entirely circumventing the whole point of the unload check - it would permit you to double add cmodes :).

I'll have a look to see where we should make this change so that they are unloaded and marked as such safely - my guess is there's an issue in unload logic - I should have something for you in next day-ish.

Thanks!
Travis

katsklaw

2015-01-01 19:23

reporter   ~0018281

I think it's bad juju to allow chanmodes to be unloaded on-the-fly in the first place.

imvho, all channel modes should be perm to prevent desyncs.

tmcarthur

2015-06-01 04:02

reporter   ~0018380

Ope got my logic backwards, this fix should work fine

Issue History

Date Modified Username Field Change
2014-08-18 20:31 hyperi0n New Issue
2014-08-18 20:34 tmcarthur Note Added: 0018225
2014-08-18 20:34 tmcarthur Assigned To => tmcarthur
2014-08-18 20:34 tmcarthur Status new => acknowledged
2014-08-19 13:25 hyperi0n Note Added: 0018226
2014-08-19 16:28 Stealth Note Added: 0018227
2014-08-19 16:31 Stealth Note Added: 0018228
2014-08-19 16:48 tmcarthur Note Added: 0018229
2014-08-19 21:46 hyperi0n Note Added: 0018230
2014-08-19 22:17 tmcarthur Note Added: 0018232
2014-08-21 22:59 hyperi0n Note Added: 0018233
2014-08-23 06:47 tmcarthur Note Added: 0018237
2015-01-01 19:23 katsklaw Note Added: 0018281
2015-06-01 04:02 tmcarthur Note Added: 0018380
2015-06-01 04:04 tmcarthur Status acknowledged => resolved
2015-06-01 04:04 tmcarthur Resolution open => fixed
2017-01-06 15:48 syzop Category module => module api