fix(vpn): apply mobile memory limits on iOS only#541
Conversation
Android does not appear to apply memory restrictions, so the limits are unnecessary there and only constrain available memory.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthrough
ChangesiOS Memory Tuning
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~2 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Pull request overview
This PR adjusts tunnel initialization to apply Go runtime/conntrack memory tuning only on iOS, aligning the behavior with iOS’s enforced memory constraints while avoiding ineffective limits on Android.
Changes:
- Switch memory-limit gating from
common.IsMobile()tocommon.IsIOS()intunnel.init. - Add an inline rationale comment explaining the iOS-only behavior.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This pull request updates the logic for setting memory limits in the
tunnelinitialization process. Now, memory limits are only set on iOS devices, rather than on all mobile platforms.Platform-specific behavior:
common.IsMobile()tocommon.IsIOS()intunnel.goto ensure memory limits are only applied on iOS, since Android does not enforce these restrictions.Summary by CodeRabbit