From 600f81148be4d08b6b1c308165b3eff1c30ac216 Mon Sep 17 00:00:00 2001 From: Garrett D'Amore Date: Mon, 18 Nov 2024 20:24:16 -0800 Subject: url: Use NNG_EINVAL for parse failures --- src/core/url.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/core/url.c') diff --git a/src/core/url.c b/src/core/url.c index 4be730cc..74346437 100644 --- a/src/core/url.c +++ b/src/core/url.c @@ -434,7 +434,7 @@ nng_url_parse(nng_url **urlp, const char *raw) // make sure only one '@' appears in the host (only one user // info is allowed) if (strchr(url->u_hostname, '@') != NULL) { - rv = NNG_EADDRINVAL; + rv = NNG_EINVAL; goto error; } } @@ -500,7 +500,7 @@ nng_url_parse(nng_url **urlp, const char *raw) } // hostname length check if (strlen(url->u_hostname) >= 256) { - rv = NNG_EADDRINVAL; + rv = NNG_EINVAL; goto error; } -- cgit v1.2.3-70-g09d2