On Wed, Feb 27, 2008 at 05:27:33PM +0100, Jim Meyering wrote:
Whoops. You'll want to close that file descriptor.
E.g., put this right before "argv = NULL;":
if (close (ret))
return -1;
It'd be nice to declare a new variable, say fd, for that bit.
Oh yes, that would be a good idea :-)
Rich.
--
Richard Jones, Emerging Technologies, Red Hat
http://et.redhat.com/~rjones
virt-top is 'top' for virtual machines. Tiny program with many
powerful monitoring features, net stats, disk stats, logging, etc.
http://et.redhat.com/~rjones/virt-top