]> jfr.im git - irc/unrealircd/unrealircd.git/commitdiff
Fix possible REHASH crash in some circumstances (also in 6.1.*)
authorBram Matthys <redacted>
Sat, 7 Oct 2023 15:23:02 +0000 (17:23 +0200)
committerBram Matthys <redacted>
Sat, 7 Oct 2023 16:39:49 +0000 (18:39 +0200)
If you make a parser mistake in the config file, like a missing semicolon,
then under some circumstances the server may crash. Not always, it seems,
which explains why this bug is not reported that much.

src/conf.c

index 636235bfc40d5449015702441b3b77e5f409f770..c39521d6a17d1150741b3938c9137f0e4698e13f 100644 (file)
@@ -2034,6 +2034,7 @@ void config_load_failed(void)
        if (conf)
                unreal_log(ULOG_ERROR, "config", "CONFIG_NOT_LOADED", NULL, "IRCd configuration failed to load");
        loop.config_status = CONFIG_STATUS_ROLLBACK;
+       loop.rehashing = 0;
        Unload_all_testing_modules();
        free_all_config_resources();
        config_free(conf);