Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/nc nc(1): Declare and initialize ``on'' ifdef SO_BIN...



details:   https://anonhg.NetBSD.org/src/rev/546b0ae7fd2f
branches:  trunk
changeset: 376486:546b0ae7fd2f
user:      rin <rin%NetBSD.org@localhost>
date:      Tue Jun 20 08:51:24 2023 +0000

description:
nc(1): Declare and initialize ``on'' ifdef SO_BINDANY. NFC yet for us.

diffstat:

 usr.bin/nc/netcat.c |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (22 lines):

diff -r 969b23fea224 -r 546b0ae7fd2f usr.bin/nc/netcat.c
--- a/usr.bin/nc/netcat.c       Tue Jun 20 07:46:03 2023 +0000
+++ b/usr.bin/nc/netcat.c       Tue Jun 20 08:51:24 2023 +0000
@@ -27,7 +27,7 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: netcat.c,v 1.6 2019/10/03 01:15:19 sevan Exp $");
+__RCSID("$NetBSD: netcat.c,v 1.7 2023/06/20 08:51:24 rin Exp $");
 
 /*
  * Re-written nc(1) for OpenBSD. Original implementation by
@@ -915,6 +915,9 @@ remote_connect(const char *host, const c
 {
        struct addrinfo *res, *res0;
        int s = -1, error, save_errno;
+#ifdef SO_BINDANY
+       int on = 1;
+#endif
 
        if ((error = getaddrinfo(host, port, &hints, &res0)))
                errx(1, "getaddrinfo: %s", gai_strerror(error));



Home | Main Index | Thread Index | Old Index