manual: Fix termios.c example. (Bug 31078)
commit3cbaacdfd2c11cb726011ef6464dce00c186a2bf
authorCarlos O'Donell <carlos@redhat.com>
Mon, 20 Nov 2023 18:15:34 +0000 (20 13:15 -0500)
committerCarlos O'Donell <carlos@redhat.com>
Mon, 20 Nov 2023 21:42:23 +0000 (20 16:42 -0500)
tree76f43f0aab043d33a9f9d1c950db35d4a4aecac1
parenta8830c928540011120ac742d632ed51d52af01df
manual: Fix termios.c example. (Bug 31078)

Remove the unused 'char *name;' from the example.

Use write instead of putchar to write input as it is read.

Example tested on x86_64 by compiling and running the example.

Tested by building the manual pdf and reviewing the results.

Reviewed-by: Florian Weimer <fweimer@redhat.com>
manual/examples/termios.c