console: TIOCSWINSZ ioctl (to set window size), without SIGWINCH
posix: use flags correctly in open() when checking for O_NOCTTY.
login: only dup2 if the fd we got from open() wasn't actually zero.
TUI: call TIOCSWINSZ on init and when we get resized