Skip to content

psh/sysexec: Redirect stdin to /dev/null instead of closing#234

Open
Darchiv wants to merge 1 commit intomasterfrom
Darchiv/RTOS-1007
Open

psh/sysexec: Redirect stdin to /dev/null instead of closing#234
Darchiv wants to merge 1 commit intomasterfrom
Darchiv/RTOS-1007

Conversation

@Darchiv
Copy link
Member

@Darchiv Darchiv commented Feb 25, 2025

JIRA: RTOS-1007

Description

Motivation and Context

sysexec -d (without -s option) closes stdin and leaves the underlying fd closed for the executed program, making stdin stream unusable at program startup. This can cause problems for programs which (correctly) assume that stdio is ready/open at startup, for example: #232

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Chore (refactoring, style fixes, git/CI config, submodule management, no code logic changes)

How Has This Been Tested?

  • Already covered by automatic testing.
  • New test added: (add PR link here).
  • Tested by hand on: (list targets here).

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing linter checks and tests passed.
  • My changes generate no new compilation warnings for any of the targets.

Special treatment

  • This PR needs additional PRs to work (list the PRs, preferably in merge-order).
  • I will merge this PR by myself when appropriate.

@github-actions
Copy link

github-actions bot commented Feb 25, 2025

Unit Test Results

7 011 tests   - 947   6 535 ✅  - 881   36m 30s ⏱️ - 3m 32s
  413 suites  -  57     475 💤  -  67 
    1 files   ±  0       1 ❌ +  1 

For more details on these failures, see this check.

Results for commit 9bd65f6. ± Comparison against base commit e2c7a67.

This pull request removes 947 tests.
phoenix-rtos-tests/cpp/hello-cpp ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/cpp/hello-cpp
phoenix-rtos-tests/initfini/main ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/initfini/main
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.data_in
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.data_in_big
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.data_inout
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.data_inout_big
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.data_out
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.data_out_big
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.in_val
phoenix-rtos-tests/ioctl/unit ‑ armv7a9-zynq7000-zedboard:phoenix-rtos-tests/ioctl/unit.ioctl.invalid_req
…

♻️ This comment has been updated with latest results.

Copy link
Member

@agkaminski agkaminski left a comment

Choose a reason for hiding this comment

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

I wonder if -s option is even still needed after this change

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.

3 participants

Comments