]> xenbits.xensource.com Git - xen.git/commitdiff
Without this we leak an fd on each domain shutdown and eventually run
authorStefano Stabellini <sstabellini@xensource.com>
Mon, 19 Jul 2010 11:21:24 +0000 (12:21 +0100)
committerStefano Stabellini <sstabellini@xensource.com>
Mon, 19 Jul 2010 11:21:24 +0000 (12:21 +0100)
out of file descriptors meaning new the console of new domains are not
logged.

Seems to have been accidentally removed in 16638:28921e83000b.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
tools/console/daemon/io.c

index 7688a1a9e46bd6c94d7a3f7ce8d67e9c007dec1c..2fd9b523d8cd80e1458f91834df1db273f193bd9 100644 (file)
@@ -747,6 +747,11 @@ static void cleanup_domain(struct domain *d)
 {
        domain_close_tty(d);
 
+       if (d->log_fd != -1) {
+               close(d->log_fd);
+               d->log_fd = -1;
+       }
+
        free(d->buffer.data);
        d->buffer.data = NULL;