mirror of
https://github.com/apache/nuttx-apps.git
synced 2026-08-01 20:29:00 +00:00
apps/examples/pty_test: If CONFIG_SERIAL_TERMIOS is not selected, then don't call tcgetattr or tcsetattr.
This commit is contained in:
parent
7f6a21ecac
commit
1a6bb2a47c
1 changed files with 2 additions and 0 deletions
|
|
@ -324,6 +324,7 @@ int pty_test_main(int argc, char *argv[])
|
|||
goto error_serial;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SERIAL_TERMIOS
|
||||
/* Enable \n -> \r\n conversion during write */
|
||||
|
||||
ret = tcgetattr(termpair.fd_uart, &tio);
|
||||
|
|
@ -340,6 +341,7 @@ int pty_test_main(int argc, char *argv[])
|
|||
fprintf(stderr, "ERROR: tcsetattr() failed: %d\n", errno);
|
||||
goto error_serial;
|
||||
}
|
||||
#endif
|
||||
|
||||
printf("Starting a new NSH Session using %s\n", buffer);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue