Skip to content

fix: check state when completing commands - #5401

Merged
Mm2PL merged 4 commits into
Chatterino:masterfrom
Nerixyz:fix/bad-meta-plugin
Jun 19, 2024
Merged

Mm2PL merged 4 commits into
Chatterino:masterfrom
Nerixyz:fix/bad-meta-plugin

Conversation

@Nerixyz

@Nerixyz Nerixyz commented May 17, 2024

Copy link
Copy Markdown
Contributor

A plugin with invalid metadata (e.g. a plugin for testing #5383 loaded in a regular version) will cause a segfault when completing commands, because its state is nullptr. This adds a check for the state. There should probably a method like isLoaded or isEnabled or isEnabledAndLoaded that does these checks in the future, because currently, even disabled plugins will be checked for completions (they don't have any completion callback, so it's fine [for now]).

@Mm2PL Mm2PL changed the title fix: check state when completing commmands fix: check state when completing commands May 17, 2024
@pajlada
pajlada requested a review from Mm2PL May 18, 2024 09:38
@Mm2PL
Mm2PL enabled auto-merge (squash) June 19, 2024 12:18
@Mm2PL
Mm2PL merged commit 052dbd7 into Chatterino:master Jun 19, 2024
@Nerixyz
Nerixyz deleted the fix/bad-meta-plugin branch June 19, 2024 15:05
babicekmarek pushed a commit to babicekmarek/streamally-chatterino that referenced this pull request Sep 14, 2026
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.

3 participants