pkg / term

Package term manages POSIX terminals.
BSD 2-Clause "Simplified" License
393 stars 64 forks source link

Fix termios constants on PPC architectures #60

Closed ssgelm closed 3 years ago

ssgelm commented 3 years ago

Some architectures, notably PPC and MIPS, use different ioctls for termios. This changes the constants to use the ones defined in golang.org/x/sys/unix which should handle edge case architectures better.

For example, you can see at https://elixir.bootlin.com/linux/latest/source/arch/powerpc/include/uapi/asm/ioctls.h, or more clearly at https://github.com/google/syzkaller/blob/master/sys/linux/dev_ptmx.txt.const that some arches have different ioctls for termios.