cnping

Minimal Graphical Ping Tool
git clone https://git.sinitax.com/cnlohr/cnping
Log | Files | Refs | Submodules | README | LICENSE | sfeed.txt

commit 9af3b2d01aa25ee92f0e0aa9606e0ee65c2164b8
parent 0c147b1adcd3984bae29c89a7fb8f207c20b8b0f
Author: mrbesen <y.g.2@gmx.de>
Date:   Thu, 15 Sep 2022 03:20:22 +0200

add usefull error message in case getaddrinfo returns an adress to big for addr to handle

Diffstat:
Mresolve.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/resolve.c b/resolve.c @@ -52,6 +52,7 @@ int resolveName(struct sockaddr* addr, socklen_t* addr_len, const char* hostname if(res->ai_addrlen > *addr_len) { // error - this should not happen + ERRM( "Error addr is to short. required length: %d, available length: %d", res->ai_addrlen, *addr_len ); freeaddrinfo(res); exit( -1 ); }