Skip to content

nsh/echo: Fix echo command to keep original behavior adding a '\n' as a single write()#3565

Open
acassis wants to merge 1 commit into
apache:masterfrom
acassis:fix_nsh_echo
Open

nsh/echo: Fix echo command to keep original behavior adding a '\n' as a single write()#3565
acassis wants to merge 1 commit into
apache:masterfrom
acassis:fix_nsh_echo

Conversation

@acassis

@acassis acassis commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Summary

This commit fixes the previous behavior where an echo with a single string and its default new line is send as single write().

This issue came from: #1559

Impact

Keep original behavior of echo command

Testing

nsh> echo Hello
Hello

nsh> echo "Hello World"
Hello World

nsh> echo "Hello" "World"
Hello World

nsh> echo "t120o1l16b9n0baan0bn0bn0baaan0b9n0baan0b" > /dev/tone0
Received 41 byte(s)
nsh>

This commit fixes the previous behavior where an echo with a
single string and its default new line is send as single write().

This issue came from:  apache#1559

Signed-off-by: Alan C. Assis <acassis@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant