Skip to content

Residual: full selftest suite 0xC0000005 at final process exit (distinct from #647 cross-fixture poisoning) #680

Closed

Description

Summary

After #647 / PR #673 eliminated the cross-fixture multi-window teardown poisoning (a torn-off floating window being elected fallback PrimaryWindow → OnPrimaryWindowClosed → SafeExit → Application.Exit() firing Closed on the shared harness window → next fixture writing SystemBackdrop onto the dead window = 0xC0000005), a distinct, residual access violation remains: the full selftest suite still faults with 0xC0000005 at final process teardown when every fixture runs together in one process.

Distinct from #647

Repro

Run the full selftest suite in one process (ARM64 reproduces most readily):

dotnet run --project tests\Reactor.AppTests.Host -p:Platform=ARM64 --no-build -- --self-test

→ # Total failures: 0 (all fixtures pass), but the process exits with 0xC0000005 during final teardown. No individual subset reproduces it.

Suspected direction

Same umbrella as the original #647 analysis: a deterministic, idempotent pre-native-destroy teardown applied uniformly across all windows during Application.Exit(), and idempotent interop unregister (SetTitleBar / WindowMessageMonitor / backdrop) so the mass-Closed cascade at process exit can't release an object twice or touch an already-destroyed owner. The closed-window registry introduced in PR #673 (BackdropApplier.s_closedWindows) may be extendable to cover the remaining write/release sites that fault at shutdown.

Related

Activity

  1. added a commit that references this issue on Jun 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions