svn commit: r323680 - releng/10.4/lib/libfetch

Marius Strobl marius at FreeBSD.org
Sun Sep 17 16:45:13 UTC 2017


Author: marius
Date: Sun Sep 17 16:45:12 2017
New Revision: 323680
URL: https://svnweb.freebsd.org/changeset/base/323680

Log:
  MF10: r323660, MFC: r322669
  
  In fetch_resolve() if the port number or service name is included
  in the host argument (e. g. "www.freebsd.org:443"), correctly set
  the service pointer accordingly.  Previously, the service pointer
  was set to the separator instead, causing getaddrinfo(3) to fail.
  
  Approved by:	re (kib)

Modified:
  releng/10.4/lib/libfetch/common.c
Directory Properties:
  releng/10.4/   (props changed)

Modified: releng/10.4/lib/libfetch/common.c
==============================================================================
--- releng/10.4/lib/libfetch/common.c	Sun Sep 17 15:58:16 2017	(r323679)
+++ releng/10.4/lib/libfetch/common.c	Sun Sep 17 16:45:12 2017	(r323680)
@@ -291,7 +291,7 @@ fetch_resolve(const char *addr, int port, int af)
 			goto syserr;
 		service = sbuf;
 	} else if (*sep != '\0') {
-		service = sep;
+		service = sep + 1;
 	} else {
 		service = NULL;
 	}


More information about the svn-src-all mailing list