Skip to content

Fix .reload to boot dangling users not in reloaded userfile - #1934

Open
michaelortmann wants to merge 2 commits into
eggheads:developfrom
michaelortmann:fix.reload
Open

michaelortmann wants to merge 2 commits into
eggheads:developfrom
michaelortmann:fix.reload

Conversation

@michaelortmann

@michaelortmann michaelortmann commented Sep 1, 2026

Copy link
Copy Markdown
Member

Found by: michaelortmann
Patch by: michaelortmann
Fixes: #1933

One-line summary:
Fix .reload to boot dangling users not in reloaded userfile
Fix small memleak under rare conditions described in #1933, plus user needs channel master priviledge to cause it
Bug found with fuzzing, fixed without any AI

Additional description (if needed):
Also added a debug warning message when set_user() is called with a NULL parameter

Test cases demonstrating functionality (if applicable):
Before:
memleak, see #1933
and user remains on partyline
After:
no memleak anymore
and dangling user is booted:

.handle foo
[14:44:36] Switched 0 notes from mallory to foo.
*** Handle change: mallory -> foo
[14:44:36] #mallory# handle foo
Okay, changed.
.reload
[14:44:38] #foo# reload
Reloading user file...
[14:44:38] Userfile loaded, unpacking...
-=- poof -=-
You've been booted from the bot by -RELOAD: user not in reloaded userfile
Connection closed by foreign host.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fccc81bb45

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread src/chanprog.c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Memory leak with console.mod and issues in core

1 participant