Skip to content

Conversation

@mcourteaux
Copy link
Contributor

@mcourteaux mcourteaux commented Nov 5, 2025

Description

  • fix(launch): Boost split_unix/split_winmain can throw exceptions, which disrupted control flow. Surrounded with try-catch, reporting a helpful message.
    • For me, split_unix was throwing on \! as escape sequence. The \ got added by saving/loading the json file I think, not sure.
  • improve(launch): In case unexpected exceptions are thrown during launch or resume, an empty an error is now logged to help the user analyze this.
  • fix(process): child.wait() may throw, replaced it with the std::error_code variant.

This fixes the Malformed XML error moonlight-qt showed in my situation.

Screenshot

Issues Fixed or Closed

Resolves #4038.

Roadmap Issues

Type of Change

  • feat: New feature (non-breaking change which adds functionality)
  • fix: Bug fix (non-breaking change which fixes an issue)
  • docs: Documentation only changes
  • style: Changes that do not affect the meaning of the code (white-space, formatting, missing semicolons, etc.)
  • refactor: Code change that neither fixes a bug nor adds a feature
  • perf: Code change that improves performance
  • test: Adding missing tests or correcting existing tests
  • build: Changes that affect the build system or external dependencies
  • ci: Changes to CI configuration files and scripts
  • chore: Other changes that don't modify src or test files
  • revert: Reverts a previous commit
  • BREAKING CHANGE: Introduces a breaking change (can be combined with any type above)

Checklist

  • Code follows the style guidelines of this project
  • Code has been self-reviewed
  • Code has been commented, particularly in hard-to-understand areas
  • Code docstring/documentation-blocks for new or existing methods/components have been added or updated
  • Unit tests have been added or updated for any new or modified functionality

AI Usage

  • None: No AI tools were used in creating this PR
  • Light: AI provided minor assistance (formatting, simple suggestions)
  • Moderate: AI helped with code generation or debugging specific parts
  • Heavy: AI generated most or all of the code changes

@mcourteaux mcourteaux changed the title Fix a few launch failures (moonlight-qt reporting Malformed XML). fix(launch): Fix several launch failure conditions (exceptions thrown in child.wait, and boost::split_unix). Nov 5, 2025
@codecov
Copy link

codecov bot commented Nov 5, 2025

Bundle Report

Bundle size has no change ✅

@codecov
Copy link

codecov bot commented Nov 5, 2025

Codecov Report

❌ Patch coverage is 0% with 17 lines in your changes missing coverage. Please review.
✅ Project coverage is 14.19%. Comparing base (1d6d916) to head (238312d).
⚠️ Report is 1 commits behind head on master.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
src/process.cpp 0.00% 9 Missing and 4 partials ⚠️
src/nvhttp.cpp 0.00% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4390      +/-   ##
==========================================
- Coverage   14.94%   14.19%   -0.76%     
==========================================
  Files          63       89      +26     
  Lines       13726    18936    +5210     
  Branches     6476     8677    +2201     
==========================================
+ Hits         2052     2688     +636     
- Misses       8686    12969    +4283     
- Partials     2988     3279     +291     
Flag Coverage Δ
FreeBSD-14.3-aarch64 ?
FreeBSD-14.3-amd64 13.52% <0.00%> (-0.03%) ⬇️
Linux-AppImage 11.55% <0.00%> (-0.02%) ⬇️
Windows-AMD64 13.34% <0.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/nvhttp.cpp 18.35% <0.00%> (+0.45%) ⬆️
src/process.cpp 1.03% <0.00%> (-0.05%) ⬇️

... and 52 files with indirect coverage changes

@ReenigneArcher ReenigneArcher changed the title fix(launch): Fix several launch failure conditions (exceptions thrown in child.wait, and boost::split_unix). fix(launch): Fix several launch failure conditions (exceptions thrown in child.wait, and boost::split_unix) Nov 5, 2025
@mcourteaux
Copy link
Contributor Author

Can somebody update me on this? Should anything happen before merge?

@ReenigneArcher

This comment was marked as resolved.

@mcourteaux

This comment was marked as resolved.

@mcourteaux

This comment was marked as resolved.

@ReenigneArcher

This comment was marked as resolved.

…ch disrupted control flow. Surrounded with try-catch, reporting a helpful message.

improve(launch): In case unexpected exceptions are thrown during launch or resume, an empty an error is now logged to help the user analyze this.
fix(process): child.wait() may throw, replaced it with the std::error_code variant.
@mcourteaux

This comment was marked as resolved.

@sonarqubecloud
Copy link

@ReenigneArcher ReenigneArcher merged commit 852dee0 into LizardByte:master Nov 12, 2025
51 of 53 checks passed
qiin2333 pushed a commit to qiin2333/foundation-sunshine that referenced this pull request Nov 14, 2025
ShadowLemoon added a commit to ShadowLemoon/Sunshine-Foundation that referenced this pull request Nov 17, 2025
…s thrown in child.wait, and boost::split_unix) (LizardByte#4390)"

This reverts commit 57f0263.
ShadowLemoon added a commit to ShadowLemoon/Sunshine-Foundation that referenced this pull request Nov 17, 2025
…s thrown in child.wait, and boost::split_unix) (LizardByte#4390)"

This reverts commit 57f0263.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Malformed XML error when trying to connect after a previous session

2 participants