14 Apr
2016
14 Apr
'16
1:57 p.m.
On Thu, Apr 14, 2016 at 07:38:23AM -0600, Eric Blake wrote:
+ /* Read the umask. */ + if (read (fd[0], &mask, sizeof mask) != sizeof mask) { + perrorf (g, "read"); + close (fd[0]); + return -1;
Oops - this strands a child process. You have to reap the child, even if the read() failed.
Bleah that was stupid. Try attached version - the only difference is I added a waitpid call to the error path above. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://people.redhat.com/~rjones/virt-df/