1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 20:17:44 +00:00

echo: Obey -n when text is empty

This commit is contained in:
Rodrigo Tobar 2021-11-01 10:19:12 +08:00 committed by Andreas Kling
parent 8e6de62d57
commit 866c9cc1a5

View file

@ -114,7 +114,8 @@ int main(int argc, char** argv)
args_parser.parse(argc, argv);
if (text.is_empty()) {
outln();
if (!no_trailing_newline)
outln();
return 0;
}