diff --git a/src/core/socket.c b/src/core/socket.c index 9e0f84e3d..1b1479435 100644 --- a/src/core/socket.c +++ b/src/core/socket.c @@ -776,7 +776,11 @@ int osmo_sock_init2_multiaddr(uint16_t family, uint16_t type, uint8_t proto, if (((flags & OSMO_SOCK_F_BIND) && (flags & OSMO_SOCK_F_CONNECT)) && !addrinfo_has_in6addr_any((const struct addrinfo **)res_loc, local_hosts_cnt) && (loc_has_v4addr != rem_has_v4addr || loc_has_v6addr != rem_has_v6addr)) { - LOGP(DLGLOBAL, LOGL_ERROR, "Invalid v4 vs v6 in local vs remote addresses\n"); + LOGP(DLGLOBAL, LOGL_ERROR, "Invalid v4 vs v6 in local vs remote addresses: " + "local:%s%s remote:%s%s\n", + loc_has_v4addr ? " v4" : "", loc_has_v6addr ? " v6" : "", + rem_has_v4addr ? " v4" : "", rem_has_v6addr ? " v6" : "" + ); rc = -EINVAL; goto ret_freeaddrinfo; } diff --git a/tests/socket/socket_sctp_test.err b/tests/socket/socket_sctp_test.err index 996d0922a..7583a2a29 100644 --- a/tests/socket/socket_sctp_test.err +++ b/tests/socket/socket_sctp_test.err @@ -1,8 +1,8 @@ invalid: you have to specify either BIND or CONNECT flags -Invalid v4 vs v6 in local vs remote addresses -Invalid v4 vs v6 in local vs remote addresses +Invalid v4 vs v6 in local vs remote addresses: local: v4 remote: v6 +Invalid v4 vs v6 in local vs remote addresses: local: v6 remote: v4 invalid: you have to specify either BIND or CONNECT flags -Invalid v4 vs v6 in local vs remote addresses -Invalid v4 vs v6 in local vs remote addresses +Invalid v4 vs v6 in local vs remote addresses: local: v4 remote: v6 +Invalid v4 vs v6 in local vs remote addresses: local: v6 remote: v4 getaddrinfo(::1, 0) failed: Address family for hostname not supported getaddrinfo(127.0.0.1, 0) failed: Address family for hostname not supported