Skip to content

Conversation

@aristarhoskal
Copy link

Fixes #10021

@sylvestre
Copy link
Contributor

Could you please add a test to make sure we don't regress in the future?
Thanks

@aristarhoskal
Copy link
Author

I added two tests:

  1. test_nohup_output_permissions: Verifies the standard output file has 0600 permissions.
  2. test_nohup_fallback_output_permissions: Verifies the fallback file in $HOME also has 0600 permissions.

@sylvestre
Copy link
Contributor

Please run cargo fmt

@github-actions
Copy link

github-actions bot commented Jan 3, 2026

GNU testsuite comparison:

GNU test failed: tests/tty/tty-eof. tests/tty/tty-eof is passing on 'main'. Maybe you have to rebase?

@aristarhoskal aristarhoskal force-pushed the fix_nohup_permissions branch from e315f9c to 87dbd01 Compare January 3, 2026 19:50
homeout.push(NOHUP_OUT);
let homeout_str = homeout.to_str().unwrap();
match OpenOptions::new().create(true).append(true).open(&homeout) {
match OpenOptions::new()
Copy link
Contributor

Choose a reason for hiding this comment

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

please create a function for OpenOptions::new()
as it is duplicated from line 140

@aristarhoskal aristarhoskal force-pushed the fix_nohup_permissions branch 2 times, most recently from 785202c to d1e3ffd Compare January 4, 2026 20:07
@github-actions
Copy link

github-actions bot commented Jan 5, 2026

GNU testsuite comparison:

Skip an intermittent issue tests/timeout/timeout (fails in this run but passes in the 'main' branch)

@sylvestre
Copy link
Contributor

A test is missing

@aristarhoskal aristarhoskal force-pushed the fix_nohup_permissions branch from d1e3ffd to 237b8d5 Compare January 5, 2026 09:41
@github-actions
Copy link

github-actions bot commented Jan 5, 2026

GNU testsuite comparison:

Skipping an intermittent issue tests/timeout/timeout (passes in this run but fails in the 'main' branch)

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.

nohup creates world-readable output files

2 participants