Skip to content
This repository was archived by the owner on Nov 6, 2020. It is now read-only.

Careless user didn't properly escape when handling stdout #7681

Closed
ghost opened this issue Jan 23, 2018 · 5 comments
Closed

Careless user didn't properly escape when handling stdout #7681

ghost opened this issue Jan 23, 2018 · 5 comments
Labels
F2-bug 🐞 The client fails to follow expected behavior. M4-core ⛓ Core client code / Rust. Z0-unconfirmed 🤔 Issue might be valid, but it’s not yet known.
Milestone

Comments

@ghost
Copy link

ghost commented Jan 23, 2018

Debian 4.8.4-1

Parity/v1.8.6-stable-1eab85a-20180117/x86_64-linux-gnu/rustc1.23.0

.deb install, fully synced

Was grepping parity --help and forgot to escape thus breaking the pipe.

-- BAD

me@mine:~/googleskunkworks.co$ parity --help |grep "--no"
grep: option '--no' is ambiguous; possibilities: '--no-filename' '--no-messages' '--no-group-separator'
Usage: grep [OPTION]... PATTERN [FILE]...
Try 'grep --help' for more information.

====================

stack backtrace:
0: 0x55f4d8f6326c -

Thread 'main' panicked at 'Error writing Error to stdout: Error { repr: Os { code: 32, message: "Broken pipe" } }', /checkout/src/libcore/result.rs:906

This is a bug. Please report it at:

https://github.com/paritytech/parity/issues/new

-- GOOD

me@mine:~/googleskunkworks.co$ parity --help |grep "--no"

@ghost
Copy link
Author

ghost commented Jan 23, 2018

This forum escaped my escape.

@5chdn 5chdn added F2-bug 🐞 The client fails to follow expected behavior. Z0-unconfirmed 🤔 Issue might be valid, but it’s not yet known. M4-core ⛓ Core client code / Rust. labels Jan 29, 2018
@5chdn 5chdn added this to the 1.10 milestone Jan 29, 2018
@5chdn
Copy link
Contributor

5chdn commented Jan 29, 2018

@axelchalon is this a bug?

@ghost
Copy link
Author

ghost commented Jan 29, 2018 via email

@tomusdrw
Copy link
Collaborator

It's a bug in Rust see: rust-lang/rust#24821

Duplicate of #4295

@ghost
Copy link
Author

ghost commented Jan 29, 2018

Ok so it seems to be a problem with Rust error handling when stdout is broken & some print statements are used.

Seems possible to fix in parity by changing how those print calls are made.

This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
F2-bug 🐞 The client fails to follow expected behavior. M4-core ⛓ Core client code / Rust. Z0-unconfirmed 🤔 Issue might be valid, but it’s not yet known.
Projects
None yet
Development

No branches or pull requests

3 participants