Always set POLLOUT on slave poll

This commit is contained in:
Kim Woelders
2018-10-15 13:36:00 +02:00
parent 540ddd5659
commit af3c3d4162
+4 -2
View File
@@ -955,13 +955,15 @@ ttynvt_poll(fuse_req_t req, struct fuse_file_info *info,
struct fuse_pollhandle *ph)
{
ttynvt_t *tty = (ttynvt_t *) (uintptr_t) info->fh;
int revents = 0;
int revents;
DBG2("%s: tty->pollin=%d tty->error/epipe=%d/%d\n",
__func__, tty->pollin, tty->error, tty->epipe);
_update_notify(tty, ph);
revents = POLLOUT;
if (tty->pollin)
{
tty->pollin = 0;
@@ -970,7 +972,7 @@ ttynvt_poll(fuse_req_t req, struct fuse_file_info *info,
if (tty->error)
{
if (tty->epipe == 0)
revents = POLLHUP | POLLIN;
revents |= POLLHUP | POLLIN;
else
revents = 0;
}