Commit 8e44c03
fix(ds): guard swapScreen KVC access with responds(to:) to prevent crash
The dual-screen viewport code accessed `swapScreen` via KVC without
checking whether the bridge implements it, causing an
NSUndefinedKeyException for melonDS, DeSmuME2015 and ThinLibretro DS
bridges.
- Use responds(to:) before value(forKey: "swapScreen") in isScreenSwapped
- Replace hardcoded "com.provenance.ds" with SystemIdentifier.DS.rawValue
Fixes Copilot review issues on PR #3377.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 341c823 commit 8e44c03
2 files changed
Lines changed: 6 additions & 4 deletions
File tree
- PVCoreBridgeRetro/Sources/PVLibRetro
- PVUI/Sources/PVUIBase/PVEmulatorVC
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
92 | | - | |
| 92 | + | |
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
| |||
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | | - | |
29 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
30 | 32 | | |
31 | 33 | | |
32 | 34 | | |
| |||
0 commit comments