Re: [libvirt] [PATCH 1/4] rpc: Don't leak fd via CreateXMLWithFiles

2016-04-29 Thread Cole Robinson
On 04/28/2016 02:55 AM, Pavel Hrdina wrote: > On Wed, Apr 27, 2016 at 06:33:58PM -0400, Cole Robinson wrote: >> From: Ben Gray >> >> FD passing APIs like CreateXMLWithFiles or OpenGraphicsFD will leak >> file descriptors. The user passes in an fd, which is dup()'d in >>

Re: [libvirt] [PATCH 1/4] rpc: Don't leak fd via CreateXMLWithFiles

2016-04-28 Thread Pavel Hrdina
On Wed, Apr 27, 2016 at 06:33:58PM -0400, Cole Robinson wrote: > From: Ben Gray > > FD passing APIs like CreateXMLWithFiles or OpenGraphicsFD will leak > file descriptors. The user passes in an fd, which is dup()'d in > virNetClientProgramCall. The new fd is what is

[libvirt] [PATCH 1/4] rpc: Don't leak fd via CreateXMLWithFiles

2016-04-27 Thread Cole Robinson
From: Ben Gray FD passing APIs like CreateXMLWithFiles or OpenGraphicsFD will leak file descriptors. The user passes in an fd, which is dup()'d in virNetClientProgramCall. The new fd is what is transfered to the server virNetClientIOWriteMessage. Once all the fds have been