Repository navigation
Conversation
| } | ||
|
|
||
| // Capture errno immediately after including Moonlight. | ||
| #include <src/moonlight_common.h> |
There was a problem hiding this comment.
If this sonar warning can't actually be corrected due to the way this test is supposed to work. You can use // NOSONAR(cpp:S954): <explain the reason here> comment
|
What stops us from just directly including the headers we care about rather than include all of |
|
Sorry for the late follow-up. I moved both wrappers into I checked the individual Moonlight headers too. |
ReenigneArcher
left a comment
There was a problem hiding this comment.
The errno-isolation change fixes a leak that is still present on current master. Please integrate the new tests with the shared fixture and add the usual include-section comments as noted inline.
Validation: all five unchanged PR tests passed in an isolated MSYS2 UCRT64 harness with system Boost 1.91. Replacing the wrapper with the original direct import made the three errno-preservation tests fail. The suggested shared-test-header replacement also passed a syntax-only compile using the project's existing test flags. git diff --check and clang-format checks on the three new files passed. This was focused validation, not a full Sunshine build or test-suite run.
The current head a1284f83ca71888dc7b5673f593b2ab118022db2 is mergeable against master (5b2a4cfdfa643b5307906c68eb122e5a34855263). Verification limit for the maintainer: Actions workflows await approval, and the GH-Pages Read the Docs job timed out waiting for its missing Actions check. SonarCloud and the main documentation build passed.
Review completed by Codex | Model: gpt-6.1-sol | Thinking: xhigh
|
Updated this to use the shared test header and added the include comments. Kept the include order needed for the errno checks. Also ran the full Windows builds and tests on ARM64 and x64. Both passed, including the errno and audio tests, with the same skips and tray exclusions as before. |
|



Description
Moonlight’s headers could redefine some Windows errno values, which I found can then leak into Boost.
These changes will now save and restore those definitions around the two existing imports. Moonlight’s own C code stays unchanged. I added regression tests too, including the case where the wrapper is the first include.
Screenshot
Issues Fixed or Closed
Roadmap Issues
Type of Change
Checklist
AI Usage
See our AI usage policy.