Re: [PATCH 1/3] tests: Return failures immediately in virErrorTestMsgs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Dec 17, 2018 at 09:55:46 -0500, John Ferlan wrote:
> Rather than chancing calling strchr when @err_noinfo == NULL or
> calling virErrorTestMsgFormatInfoOne when @err_info == NULL, both
> of which would fail, let's just return -1 immediately when we
> encounter an error.
> 
> Signed-off-by: John Ferlan <jferlan@xxxxxxxxxx>
> ---
>  tests/virerrortest.c | 11 +++++------
>  1 file changed, 5 insertions(+), 6 deletions(-)

This would make the test hard to diagnose as it spits out one failure at
time. I prefer you add the checks explicitly.

Attachment: signature.asc
Description: PGP signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux