diff --git a/nshlib/README.txt b/nshlib/README.txt index f64f39cf9..a678824e3 100644 --- a/nshlib/README.txt +++ b/nshlib/README.txt @@ -901,6 +901,12 @@ NSH-Specific Configuration Settings the system console is used to provide debug output. Default: stdin and stdout (probably "/dev/console") + NOTE: When any other device other than /dev/console is used + for a user interface, (1) linefeeds (\n) will not be expanded to + carriage return / linefeeds (\r\n). You will need to set + your terminal program to account for this. And (2) input is + not automatically echoed so you will have to turn local echo on. + * CONFIG_NSH_TELNET If CONFIG_NSH_TELNET is set to 'y', then a TELENET server front-end is selected. When this option is provided, diff --git a/nshlib/nsh_serial.c b/nshlib/nsh_serial.c index 29e60d9e3..ccb25477d 100644 --- a/nshlib/nsh_serial.c +++ b/nshlib/nsh_serial.c @@ -476,7 +476,7 @@ int nsh_consolemain(int argc, char *argv[]) /* Present a greeting */ - fprintf(pstate->ss_outstream, g_nshgreeting); + fputs(g_nshgreeting, pstate->ss_outstream); fflush(pstate->ss_outstream); /* Execute the startup script */