[libvirt] [PATCH] More coverity findings addressed

Laine Stump laine at laine.org
Sat Apr 28 01:45:28 UTC 2012


On 04/27/2012 03:17 PM, Eric Blake wrote:
> On 04/27/2012 12:34 PM, Stefan Berger wrote:
>> One note about the error in commandtest line 809: setsid() seems to fail
>> when running the test -- could be removed ?
> Odd.  I think we had to add it to make the test pass under some
> situations, so I don't think we can remove it, but I'd have to research
> why it is failing in other situations.  It may stem from the history of
> whether the test is being run from another session leader process, and
> that may differ according to whether make is running the test or you are
> doing it by hand.

Right. the man page says that setsid will fail if the process is already
the session leader. It says that in order to ensure success, you should
fork, then exit the parent and call setsid in the child.


I haven't looked at the code at all to see what circumstances would
cause it to behave differently.




More information about the libvir-list mailing list