Fix out-of-bounds crash in PluginIterator_Next (#2445)

* Fix OOB dereference in PluginIterator methodmap (#1880)

This prevents the native from returning true when the iterator has already reached the end() of the list, which previously led to a crash when accessing the Plugin property.

* Add defense-in-depth safeguards to CMMPluginIterator

* Update PluginIterator.Next() @error documentation

Reflect the new NativeError thrown when calling Next() on an exhausted iterator.
This commit is contained in:
SCP-076
2026-04-25 17:11:28 +00:00
committed by GitHub
parent 7f2528d0fa
commit 94adc98ef5
2 changed files with 11 additions and 7 deletions
+1 -1
View File
@@ -262,7 +262,7 @@ methodmap PluginIterator < Handle
// Advances the iterator. Returns whether there are more plugins available in the iterator.
//
// @return True on more plugins, false otherwise.
// @error Invalid Handle.
// @error Invalid Handle, or called when the iterator is already exhausted.
public native bool Next();
// Returns the current plugin in the iterator.