![]() | |||||||||||
Messages in this thread Patch in this message |
Hello, The rest of the kernel treats tty->driver->chars_in_buffer as a possible NULL. This patch changes normal_poll() to be consistent with the rest of the code. Signed-off-by: Dan Aloni <da-x@colinux.org> BTW, who is currently maintaining the tty subsystem? --- linux-2.6.7/drivers/char/n_tty.c 2004-06-21 09:30:11.000000000 +0300 +++ linux-2.6.7/drivers/char/n_tty.c 2004-06-21 09:28:04.000000000 +0300 @@ -1272,8 +1272,8 @@ else tty->minimum_to_wake = 1; } - if (tty->driver->chars_in_buffer(tty) < WAKEUP_CHARS && - tty->driver->write_room(tty) > 0) + if ((!tty->driver->chars_in_buffer || tty->driver->chars_in_buffer(tty) < WAKEUP_CHARS) + && tty->driver->write_room(tty) > 0) mask |= POLLOUT | POLLWRNORM; return mask; } -- Dan Aloni da-x@colinux.org - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ | ||||||||||
| Last update: 2005-03-22 14:03 [from the cache] ©2003-2008 | |||||||||||