mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 13:45:38 +00:00
tests: Fix message for IP parse/format failures
Confusing message is printed when a parse/format sockettest fails. E.g. there's a test that parses/formats ::ffff and the format fails like that: 38) Test format ::ffff family AF_UNSPEC ... Offset 2 Expect [0.0.255.255] Actual [ffff] It should be instead: 38) Test format ::ffff family AF_UNSPEC ... Offset 2 Expect [ffff] Actual [0.0.255.255] Signed-off-by: Roman Bolshakov <r.bolshakov@yadro.com> Reviewed-by: Andrea Bolognani <abologna@redhat.com>
This commit is contained in:
parent
9ce035e404
commit
6c62122e06
@ -50,7 +50,7 @@ static int testFormat(virSocketAddr *addr, const char *addrstr, bool pass)
|
||||
return pass ? -1 : 0;
|
||||
|
||||
if (STRNEQ(newaddrstr, addrstr)) {
|
||||
virTestDifference(stderr, newaddrstr, addrstr);
|
||||
virTestDifference(stderr, addrstr, newaddrstr);
|
||||
VIR_FREE(newaddrstr);
|
||||
return pass ? -1 : 0;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user