Skip to content

Fix crash in sprite list - #8920

Merged
4ian merged 1 commit into
masterfrom
claude/gdevelop-error-analysis-bc68qr
Aug 4, 2026
Merged

Fix crash in sprite list#8920
4ian merged 1 commit into
masterfrom
claude/gdevelop-error-analysis-bc68qr

Conversation

@4ian

@4ian 4ian commented Aug 4, 2026

Copy link
Copy Markdown
Owner

No description provided.

…moved or deleted

The children render-prop, beginDrag and thumbnail callbacks captured a
gd.Sprite wrapper created at render time. react-dnd re-invokes these
closures on drag monitor state changes, after direction.moveSprite() or a
deletion invalidated the underlying C++ object, causing 'memory access
out of bounds'/UseAfterFreeError crashes in the object editor (the most
frequent crash reported in 5.6.276). Closures now only capture the
sprite pointer and image name extracted at render time.

Also guard deleteSprites against reading the first sprite of an empty
first direction (Direction::GetSprite is unchecked in C++).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019tAYyjBj4D4s2h32iN1eL1
@4ian
4ian merged commit fcab0a9 into master Aug 4, 2026
5 of 6 checks passed
@4ian
4ian deleted the claude/gdevelop-error-analysis-bc68qr branch August 4, 2026 09:30
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.

2 participants