8000 stat: panic on calling with `-` and an open pipe/fifo · Issue #3485 · uutils/coreutils · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

stat: panic on calling with - and an open pipe/fifo #3485

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

Closed
jhscheer opened this issue May 5, 2022 · 0 comments · Fixed by #3498
Closed

stat: panic on calling with - and an open pipe/fifo #3485

jhscheer opened this issue May 5, 2022 · 0 comments · Fixed by #3498
Labels

Comments

@jhscheer
Copy link
Contributor
jhscheer commented May 5, 2022

The workaround from #3280 does not distinguish between calling stat - with an open pipe/fifo or without.

GNU stat:

 $ stat -
  File: -
  Size: 0               Blocks: 0          IO Block: 1024   character special file
$ echo | stat -
  File: -
  Size: 0               Blocks: 0          IO Block: 4096   fifo

uu_stat:

$ target/debug/stat -
  File: /dev/pts/7
  Size: 0               Blocks: 0          IO Block: 1024   character special file
$ echo | target/debug/stat -
thread 'main' panicked at 'unable to canonicalize /dev/stdin: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/uu/stat/src/stat.rs:482:18
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
jhscheer added a commit to jhscheer/coreutils that referenced this issue May 5, 2022
jhscheer added a commit to jhscheer/coreutils that referenced this issue 8000 May 5, 2022
jhscheer added a commit to jhscheer/coreutils that referenced this issue May 6, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
jhscheer added a commit to jhscheer/coreutils that referenced this issue May 6, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
jhscheer added a commit to jhscheer/coreutils that referenced this issue May 6, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
jhscheer added a commit to jhscheer/coreutils that referenced this issue May 6, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
jhscheer 8000 added a commit to jhscheer/coreutils that referenced this issue May 6, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
jhscheer added a commit to jhscheer/coreutils that referenced this issue May 7, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
sylvestre pushed a commit to jhscheer/coreutils that referenced this issue May 11, 2022
* fix uutils#3485
* improve the workaround from uutils#3280
* add tests
sylvestre added a commit that referenced this issue May 12, 2022
stat: improve handling of stdin/fifo (fix #3485)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants
0