qemuxml2argvmock: Fix behaviour of 'virCommandPass' mock
The 'virCommandPass' mock in 'qemuxml2argvmock.so' skipped passing most
FDs to the real implementation of 'virCommandPass', except for few fake
FDs that were hardcoded.
This meant that if a test case had an valid FD that it used for testing
that FD would be leaked. At the same time fake fds 1730, 1731, 1732
would be actually passed to the virCommand itself although the FD was
invalid.
Since neither of the above makes sense fix the implementation the
following way:
- refuse to pass any STDIO fds
They are real and they would break test program output. Some tests
do try to use them errorneously; they will be addressed later.
- pass real FDs to virCommand
Real FDs can be properly handled by virCommand. Especially they will
be closed once the virCommand object is disposed of.
- don't pass fake FDs
They create extra noise e.g. in valgrind. Skip those as it makes no
sense to handle those.
This patch addresses most failures that valgrind reports with
--track-fds=all.
Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>