hack to workaround termios not being the right size