Date: Wed, 26 Dec 2018 13:29:31 +0000 (UTC) From: Tobias Kortkamp <tobik@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r488388 - in head/net/minisapserver: . files Message-ID: <201812261329.wBQDTVcD027838@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: tobik Date: Wed Dec 26 13:29:31 2018 New Revision: 488388 URL: https://svnweb.freebsd.org/changeset/ports/488388 Log: net/minisaperver: Fix build on CURRENT broadcast.cpp:91:13: error: value of type '__bind<int &, sockaddr *, unsigned int>' is not contextually convertible to 'bool' if (bind (fd6, (struct sockaddr *)&addr, sizeof (addr))) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ http://beefy11.nyi.freebsd.org/data/head-i386-default/p488289_s342400/logs/minisapserver-0.3.8_1.log Added: head/net/minisapserver/files/patch-broadcast.cpp (contents, props changed) Modified: head/net/minisapserver/Makefile Modified: head/net/minisapserver/Makefile ============================================================================== --- head/net/minisapserver/Makefile Wed Dec 26 13:28:49 2018 (r488387) +++ head/net/minisapserver/Makefile Wed Dec 26 13:29:31 2018 (r488388) @@ -36,7 +36,6 @@ post-patch: ${WRKSRC}/configure @${REINPLACE_CMD} -e 's|/etc/sap.cfg|${PREFIX}/etc/sap.cfg|' \ ${WRKSRC}/sapserver.h - @${REINPLACE_CMD} -e 's|a6->sin_len|a6->sin6_len|g' ${WRKSRC}/broadcast.cpp @${CP} -f ${WRKSRC}/sap.cfg ${WRKSRC}/sap.cfg-dist .include <bsd.port.mk> Added: head/net/minisapserver/files/patch-broadcast.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/minisapserver/files/patch-broadcast.cpp Wed Dec 26 13:29:31 2018 (r488388) @@ -0,0 +1,33 @@ +broadcast.cpp:91:13: error: value of type '__bind<int &, sockaddr *, unsigned long>' is not contextually convertible to 'bool' + if (bind (fd6, (struct sockaddr *)&addr, sizeof (addr))) + ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +--- broadcast.cpp.orig 2010-10-09 16:04:27 UTC ++++ broadcast.cpp +@@ -88,7 +88,7 @@ Broadcast::Broadcast(int i_ttl, const char *psz_iface) + setsockopt (fd6, IPPROTO_IPV6, IPV6_MULTICAST_HOPS, + &i_ttl, sizeof(i_ttl)); + +- if (bind (fd6, (struct sockaddr *)&addr, sizeof (addr))) ++ if (::bind (fd6, (struct sockaddr *)&addr, sizeof (addr))) + { + close (fd6); + fd6 = -1; +@@ -143,7 +143,7 @@ Broadcast::Broadcast(int i_ttl, const char *psz_iface) + setsockopt (fd4, IPPROTO_IP, IP_MULTICAST_TTL, &ttl, 1); + } + +- if (bind (fd4, (struct sockaddr *)&addr, sizeof (addr))) ++ if (::bind (fd4, (struct sockaddr *)&addr, sizeof (addr))) + { + close (fd4); + fd4 = -1; +@@ -281,7 +281,7 @@ int Broadcast::GuessDestination (const char *str, + memset (a6, 0, sizeof (*a6)); + a6->sin6_family = AF_INET6; + #ifdef HAVE_SA_LEN +- a6->sin_len = sizeof (*a6); ++ a6->sin6_len = sizeof (*a6); + #endif + a6->sin6_scope_id = scope_id; + a6->sin6_port = htons (HELLO_PORT);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201812261329.wBQDTVcD027838>