Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Launcher: Allow setting a distinct stderr redirect #1329

Merged
merged 3 commits into from
Jul 13, 2023

Conversation

s1341
Copy link
Collaborator

@s1341 s1341 commented Jun 29, 2023

No description provided.

if let Some(stderr) = stderr_file {
dup2(stderr.as_raw_fd(), libc::STDERR_FILENO)?;
} else {
dup2(file.as_raw_fd(), libc::STDERR_FILENO)?;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably also happen when debug_output is set(?)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you mean?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If debug_output is true, the redirect won't happen, not sure if that's what we want?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if debug_output is true, we're supposed to ignore the stdout/stderr redirections and just let things go to original stdout/stderr, no?

@domenukk domenukk merged commit 11fc57a into main Jul 13, 2023
@domenukk domenukk deleted the launcher_allow_setting_stderr branch July 13, 2023 20:50
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.

2 participants