Fix CTD on teleport#349
Conversation
Fix a CTD encountered upon teleport.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughSummary by CodeRabbit
WalkthroughIn ChangesCapabilities Update Deferral
Estimated code review effort: 2 (Simple) | ~10 minutes Sequence Diagram(s)sequenceDiagram
participant Coroutine as requestBaseCapabilitiesCoro
participant AppViewer as LLAppViewer
participant Region as LLViewerRegion
Coroutine->>AppViewer: postToMainCoro(callback with regionHandle)
AppViewer->>Region: getRegion(regionHandle)
alt region exists
AppViewer->>Region: setCapabilitiesReceived(true)
alt ServerReleaseNotes available and requested
AppViewer->>Region: showReleaseNotes()
end
else region no longer exists
AppViewer-->>Coroutine: abort callback
end
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@indra/newview/llviewerregion.cpp`:
- Around line 399-413: The deferred callback in
LLViewerRegion::setCapabilitiesReceived() dereferences LLWorld::getInstance()
after posting to the main coro, but LLWorld may already be torn down by then.
Update the lambda to first grab and null-check the LLWorld singleton before
calling getRegionFromHandle(regionHandle), and return early if it is
unavailable; keep the existing regionp checks and release-notes flow unchanged.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 99c12907-1cc5-417a-a99d-27a39e58d712
📒 Files selected for processing (1)
indra/newview/llviewerregion.cpp
Description
Fix a CTD encountered upon teleport - region caps processing has been moved into the main thread to avoid an assert which could be encountered when teleporting.
Related Issues
Issue Link:
Checklist
Please ensure the following before requesting review:
Additional Notes