From b25f13366c4f785638158dc62217716dcbc77cdb Mon Sep 17 00:00:00 2001 From: Azat Khuzhin Date: Sun, 18 Feb 2024 15:35:34 +0100 Subject: [PATCH] Fix documentation for return value of evutil_inet_pton() Fixes: https://github.com/libevent/libevent-book/issues/39 --- Ref5_evutil.txt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Ref5_evutil.txt b/Ref5_evutil.txt index b75d44a..ecc4f66 100644 --- a/Ref5_evutil.txt +++ b/Ref5_evutil.txt @@ -338,8 +338,9 @@ AF_INET6, the string to parse in 'src', and 'dst' pointing to an in_addr or an in_addr6 as appropriate. The return value from evutil_inet_ntop() is NULL on failure and -otherwise points to dst. The return value from evutil_inet_pton() is 0 -on success and -1 on failure. +otherwise points to dst. The return value from evutil_inet_pton() is 1 +on success, -1 if af is not supported and 0 if src does not contain a character +string representing a valid network address in the specified address family. .Interface [code,C]