Skip to content

fix(resource): expose application resource map - #587

Open
benletchford wants to merge 1 commit into
masterfrom
dev/fix-loadseg-return
Open

fix(resource): expose application resource map#587
benletchford wants to merge 1 commit into
masterfrom
dev/fix-loadseg-return

Conversation

@benletchford

Copy link
Copy Markdown
Owner

Closes #579

Cause

Systemless indexed application resources only in host-side Resource Manager state. Classic runtimes that walk TopMapHndl directly therefore saw a NIL map, failed to install their relocation hooks, and later treated segment-relative code targets as low-memory addresses. Native resource-map code also could not read the already-open application resource fork through its FCB because the serialized fork was not mounted on that path.

Fix

  • retain the serialized resource map and complete fork when parsing resources
  • publish an application resource-map handle through TopMapHndl
  • populate each resource reference record with its live guest handle
  • expose the serialized application resource fork to native PBRead calls

Evidence

The authentic issue reproducer now completes relocation, initializes QuickDraw, opens its scenario data, and reaches ExitToShell with a valid tick count instead of recursively re-entering startup and wrapping TickCount to $FFFFFFFF.

Tests

@benletchford
benletchford marked this pull request as ready for review August 13, 2026 22:38
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.

Classic segmented 68k applications can recurse through startup and corrupt TickCount

1 participant