diff options
author | Andrey A. Chernov <ache@FreeBSD.org> | 1996-03-12 10:23:30 +0000 |
---|---|---|
committer | Andrey A. Chernov <ache@FreeBSD.org> | 1996-03-12 10:23:30 +0000 |
commit | 7573cb47cf4b1f33b6794f82a8a5e0bcbdcc1ada (patch) | |
tree | b3a9e0accac35f4a1755333f602fcb6809c9d750 /usr.bin/talk | |
parent | 71d7d1b17aac58f60ca8dcc25d2e3785c8c9c081 (diff) | |
download | src-test2-7573cb47cf4b1f33b6794f82a8a5e0bcbdcc1ada.tar.gz src-test2-7573cb47cf4b1f33b6794f82a8a5e0bcbdcc1ada.zip |
Notes
Diffstat (limited to 'usr.bin/talk')
-rw-r--r-- | usr.bin/talk/get_iface.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/talk/get_iface.c b/usr.bin/talk/get_iface.c index 58defdc53969..741392e3db7e 100644 --- a/usr.bin/talk/get_iface.c +++ b/usr.bin/talk/get_iface.c @@ -29,7 +29,7 @@ * From: * Id: find_interface.c,v 1.1 1995/08/14 16:08:39 wollman Exp * - * $Id$ + * $Id: get_iface.c,v 1.1 1996/03/09 19:22:52 joerg Exp $ */ #include <unistd.h> @@ -70,7 +70,7 @@ get_iface(dst, iface) do { rv = bind(s, (struct sockaddr *)&local, sizeof local); - local.sin_port++; + local.sin_port = htons(ntohs(local.sin_port) + 1); } while(rv < 0 && errno == EADDRINUSE); if (rv < 0) { @@ -80,7 +80,7 @@ get_iface(dst, iface) do { rv = connect(s, (struct sockaddr *)&remote, sizeof remote); - remote.sin_port++; + remote.sin_port = htons(ntohs(remote.sin_port) + 1); } while(rv < 0 && errno == EADDRINUSE); if (rv < 0) { |