Repository navigation
Fix exclusive-access crash in WindowDragHandleView hitTest - #736
lawrencecchen merged 1 commit into
Conversation
Add early return for non-leftMouseDown events in DraggableView.hitTest to prevent re-entering SwiftUI view state during mouseMoved layout passes, which caused fatal exclusive-access violations.
|
@harukitosa is attempting to deploy a commit to the Manaflow Team on Vercel. A member of the Team first needs to authorize it. |
📝 WalkthroughWalkthroughAdds a guard in Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related issues
Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Greptile SummaryFixes a Swift exclusive-access crash in
Confidence Score: 5/5
Important Files Changed
Last reviewed commit: e95e6d5 |
Includes upstream hit-test crash fixes (manaflow-ai#698, manaflow-ai#736, manaflow-ai#771)
Includes upstream hit-test crash fixes (manaflow-ai#698, manaflow-ai#736, manaflow-ai#771)
…ai#736) Add early return for non-leftMouseDown events in DraggableView.hitTest to prevent re-entering SwiftUI view state during mouseMoved layout passes, which caused fatal exclusive-access violations.
Summary
WindowDragHandleView.DraggableView.hitTestmouseMovedevents, SwiftUI's internal layout pass callshitTest, which re-enters SwiftUI view state viawindowDragHandleShouldCaptureHit, triggering a fatal access conflictleftMouseDownevents before calling the heavyweight function, avoiding SwiftUI re-entry entirelyFixes #723
Root Cause
The crash occurs when:
mouseMovedevent triggers SwiftUI's internal state modificationhitTestonDraggableViewduring that modificationwindowDragHandleShouldCaptureHitaccesses SwiftUI-managed view properties before reaching the existingleftMouseDownguard, causing re-entryTest plan
Summary by CodeRabbit