Open rusty-snake opened 3 years ago
All the warnings/errors should make clear that they are printed by firejail (e.g. firejail:Error:).
This reminds me of #3325, which never really got of the ground. @topimiettinen mentioned a possibility to improve errExit() and use it everywhere with a prefix. IMO that would solve this part of the issue. Just adding it here for future reference.
I'm not sure is there a single reason to use stdout in firejail. It is a wrapper, hence it should not touch neither stdin nor stdout.
We have multiple issues about how we print something to the console, which all go to the same code. Therefore I make this meta-issue.
4168
Fixed in https://github.com/netblue30/firejail/commit/65b7cd79cf532b77b0c67fa3f94da10534e9a9b3
3125
Fixed in https://github.com/netblue30/firejail/commit/65b7cd79cf532b77b0c67fa3f94da10534e9a9b3
3503
3354
3749
4328
2322
There are some more which aren't handled here like:
2743
Fixed in https://github.com/netblue30/firejail/commit/9fd3560768a0e90f4469ae0679aba5fe632161d5 and https://github.com/netblue30/firejail/commit/9a84e4df6075b286d67b1f0d8079aed4d0b77760
Good to read:
IMHO we should only print warnings and errors to stderr by default and be quiet for everything else. The current
quiet
would be then a hard-queit if a program really need full ownership of stderr. In addition a--info
/--verbose
/--debug=1
/--debug=little
/whatever will show the current default output.All the warnings/errors should make clear that they are printed by firejail (e.g.
firejail:Error:
).For the debug output it would be enough to print something like