[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH] Fix xenconsole's "Could not read tty from store"
Oops, there may be a problem with this: John Levon, le Tue 18 Dec 2007 01:41:44 +0000, a écrit : > @@ -684,7 +720,9 @@ static void handle_tty_read(struct domai > len = sizeof(msg); > > len = read(dom->tty_fd, msg, len); > - if (len < 1) { > + if (len == 0) { > + /* slave did a close: that's fine. */ > + } else if (len < 0) { > close(dom->tty_fd); > dom->tty_fd = -1; > If the slave did a close, you have to somehow remove the fd from the select, because else you'll loop trying to read EOF. Samuel _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |