diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2024-02-26 09:59:29 +0100 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2024-02-26 09:59:29 +0100 |
commit | c2476ff6a5966e61956edb2d208fed140ae7cf55 (patch) | |
tree | 8fec731deb3b43e93521e6433752163a2726e9b5 /src/tc-socket.c | |
parent | 461d481e1a84e8e5232b471331e02ea9d63b2a2a (diff) | |
parent | 92ac2277ef889d82e56efd57a342959d8b3399d8 (diff) |
Merge branch 'feature/upstream' into develop
Diffstat (limited to 'src/tc-socket.c')
-rw-r--r-- | src/tc-socket.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/tc-socket.c b/src/tc-socket.c index 3cdeb90..2c140a1 100644 --- a/src/tc-socket.c +++ b/src/tc-socket.c @@ -17,6 +17,7 @@ static int t_parse(void) { char host[32] = "bogus"; + uint16_t port = 4321; if (HX_addrport_split("[::1]", host, sizeof(host), nullptr) != 1 || strcmp(host, "::1") != 0) return 1; @@ -26,6 +27,9 @@ static int t_parse(void) if (HX_addrport_split("", host, sizeof(host), nullptr) != 1 || strcmp(host, "") != 0) return 1; + if (HX_addrport_split("[]:", host, sizeof(host), &port) != 1 || + strcmp(host, "") != 0 || port != 0) + return 1; return 0; } |