host: Don't log port if it is zero

This commit is contained in:
Tobias Brunner
2017-03-02 08:27:30 +01:00
parent d8e12fdb13
commit 2283c8148a
2 changed files with 6 additions and 6 deletions
+5 -5
View File
@@ -657,18 +657,18 @@ END_TEST
static struct {
char *addr;
uint16_t port;
/* results for %H, %+H, %#H (falls back to [0]) */
/* results for %H, %+H, %#H (falls back to the first entry) */
char *result[3];
} printf_data[] = {
{NULL, 0, { "(null)" }},
{NULL, 500, { "(null)" }},
{"%any", 0, { "%any", "0.0.0.0", "0.0.0.0[0]" }},
{"%any", 0, { "%any", "0.0.0.0", "0.0.0.0" }},
{"%any", 500, { "%any", "0.0.0.0", "0.0.0.0[500]" }},
{"%any6", 0, { "%any6", "::", "::[0]" }},
{"%any6", 0, { "%any6", "::", "::" }},
{"%any6", 500, { "%any6", "::", "::[500]" }},
{"192.168.0.1", 0, { "192.168.0.1", "192.168.0.1", "192.168.0.1[0]" }},
{"192.168.0.1", 0, { "192.168.0.1" }},
{"192.168.0.1", 500, { "192.168.0.1", "192.168.0.1", "192.168.0.1[500]" }},
{"fec1::1", 0, { "fec1::1", "fec1::1", "fec1::1[0]" }},
{"fec1::1", 0, { "fec1::1" }},
{"fec1::1", 500, { "fec1::1", "fec1::1", "fec1::1[500]" }},
};