diff options
author | Brent Cook <busterb@gmail.com> | 2019-01-19 22:24:01 -0600 |
---|---|---|
committer | Brent Cook <busterb@gmail.com> | 2019-01-19 22:24:01 -0600 |
commit | 17ae1da6c9b10939617a6ac7dadf9454969ab0fd (patch) | |
tree | d274f9f3c8ed4a7fa2d741d6f8041cdcd6382e29 /patches/netcat.c.patch | |
parent | 7c4d13138a455c17b0f7a9e0d113adda639affb0 (diff) | |
download | portable-17ae1da6c9b10939617a6ac7dadf9454969ab0fd.tar.gz portable-17ae1da6c9b10939617a6ac7dadf9454969ab0fd.tar.bz2 portable-17ae1da6c9b10939617a6ac7dadf9454969ab0fd.zip |
rebase patches
Diffstat (limited to 'patches/netcat.c.patch')
-rw-r--r-- | patches/netcat.c.patch | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/patches/netcat.c.patch b/patches/netcat.c.patch index 2bb5bc9..03857c9 100644 --- a/patches/netcat.c.patch +++ b/patches/netcat.c.patch | |||
@@ -1,6 +1,6 @@ | |||
1 | --- apps/nc/netcat.c.orig Fri Nov 9 12:02:51 2018 | 1 | --- apps/nc/netcat.c.orig Fri Jan 18 15:41:52 2019 |
2 | +++ apps/nc/netcat.c Fri Nov 16 04:38:56 2018 | 2 | +++ apps/nc/netcat.c Sat Jan 19 22:19:23 2019 |
3 | @@ -92,9 +92,13 @@ | 3 | @@ -93,9 +93,13 @@ |
4 | int Dflag; /* sodebug */ | 4 | int Dflag; /* sodebug */ |
5 | int Iflag; /* TCP receive buffer size */ | 5 | int Iflag; /* TCP receive buffer size */ |
6 | int Oflag; /* TCP send buffer size */ | 6 | int Oflag; /* TCP send buffer size */ |
@@ -13,8 +13,8 @@ | |||
13 | +#endif | 13 | +#endif |
14 | 14 | ||
15 | int usetls; /* use TLS */ | 15 | int usetls; /* use TLS */ |
16 | char *Cflag; /* Public cert file */ | 16 | const char *Cflag; /* Public cert file */ |
17 | @@ -266,12 +270,14 @@ | 17 | @@ -268,12 +272,14 @@ |
18 | case 'u': | 18 | case 'u': |
19 | uflag = 1; | 19 | uflag = 1; |
20 | break; | 20 | break; |
@@ -29,7 +29,7 @@ | |||
29 | case 'v': | 29 | case 'v': |
30 | vflag = 1; | 30 | vflag = 1; |
31 | break; | 31 | break; |
32 | @@ -318,9 +324,11 @@ | 32 | @@ -320,9 +326,11 @@ |
33 | case 'o': | 33 | case 'o': |
34 | oflag = optarg; | 34 | oflag = optarg; |
35 | break; | 35 | break; |
@@ -41,7 +41,7 @@ | |||
41 | case 'T': | 41 | case 'T': |
42 | errstr = NULL; | 42 | errstr = NULL; |
43 | errno = 0; | 43 | errno = 0; |
44 | @@ -344,9 +352,11 @@ | 44 | @@ -346,9 +354,11 @@ |
45 | argc -= optind; | 45 | argc -= optind; |
46 | argv += optind; | 46 | argv += optind; |
47 | 47 | ||
@@ -53,7 +53,7 @@ | |||
53 | 53 | ||
54 | /* Cruft to make sure options are clean, and used properly. */ | 54 | /* Cruft to make sure options are clean, and used properly. */ |
55 | if (argv[0] && !argv[1] && family == AF_UNIX) { | 55 | if (argv[0] && !argv[1] && family == AF_UNIX) { |
56 | @@ -916,7 +926,10 @@ | 56 | @@ -918,7 +928,10 @@ |
57 | remote_connect(const char *host, const char *port, struct addrinfo hints) | 57 | remote_connect(const char *host, const char *port, struct addrinfo hints) |
58 | { | 58 | { |
59 | struct addrinfo *res, *res0; | 59 | struct addrinfo *res, *res0; |
@@ -65,7 +65,7 @@ | |||
65 | 65 | ||
66 | if ((error = getaddrinfo(host, port, &hints, &res0))) | 66 | if ((error = getaddrinfo(host, port, &hints, &res0))) |
67 | errx(1, "getaddrinfo for host \"%s\" port %s: %s", host, | 67 | errx(1, "getaddrinfo for host \"%s\" port %s: %s", host, |
68 | @@ -931,8 +944,10 @@ | 68 | @@ -933,8 +946,10 @@ |
69 | if (sflag || pflag) { | 69 | if (sflag || pflag) { |
70 | struct addrinfo ahints, *ares; | 70 | struct addrinfo ahints, *ares; |
71 | 71 | ||
@@ -76,7 +76,7 @@ | |||
76 | memset(&ahints, 0, sizeof(struct addrinfo)); | 76 | memset(&ahints, 0, sizeof(struct addrinfo)); |
77 | ahints.ai_family = res->ai_family; | 77 | ahints.ai_family = res->ai_family; |
78 | ahints.ai_socktype = uflag ? SOCK_DGRAM : SOCK_STREAM; | 78 | ahints.ai_socktype = uflag ? SOCK_DGRAM : SOCK_STREAM; |
79 | @@ -1003,7 +1018,10 @@ | 79 | @@ -1005,7 +1020,10 @@ |
80 | local_listen(const char *host, const char *port, struct addrinfo hints) | 80 | local_listen(const char *host, const char *port, struct addrinfo hints) |
81 | { | 81 | { |
82 | struct addrinfo *res, *res0; | 82 | struct addrinfo *res, *res0; |
@@ -88,7 +88,7 @@ | |||
88 | int error; | 88 | int error; |
89 | 89 | ||
90 | /* Allow nodename to be null. */ | 90 | /* Allow nodename to be null. */ |
91 | @@ -1024,9 +1042,11 @@ | 91 | @@ -1026,9 +1044,11 @@ |
92 | res->ai_protocol)) < 0) | 92 | res->ai_protocol)) < 0) |
93 | continue; | 93 | continue; |
94 | 94 | ||
@@ -100,7 +100,7 @@ | |||
100 | 100 | ||
101 | set_common_sockopts(s, res->ai_family); | 101 | set_common_sockopts(s, res->ai_family); |
102 | 102 | ||
103 | @@ -1492,11 +1512,13 @@ | 103 | @@ -1494,11 +1514,13 @@ |
104 | { | 104 | { |
105 | int x = 1; | 105 | int x = 1; |
106 | 106 | ||
@@ -114,7 +114,7 @@ | |||
114 | if (Dflag) { | 114 | if (Dflag) { |
115 | if (setsockopt(s, SOL_SOCKET, SO_DEBUG, | 115 | if (setsockopt(s, SOL_SOCKET, SO_DEBUG, |
116 | &x, sizeof(x)) == -1) | 116 | &x, sizeof(x)) == -1) |
117 | @@ -1507,9 +1529,16 @@ | 117 | @@ -1509,9 +1531,16 @@ |
118 | IP_TOS, &Tflag, sizeof(Tflag)) == -1) | 118 | IP_TOS, &Tflag, sizeof(Tflag)) == -1) |
119 | err(1, "set IP ToS"); | 119 | err(1, "set IP ToS"); |
120 | 120 | ||
@@ -131,7 +131,7 @@ | |||
131 | } | 131 | } |
132 | if (Iflag) { | 132 | if (Iflag) { |
133 | if (setsockopt(s, SOL_SOCKET, SO_RCVBUF, | 133 | if (setsockopt(s, SOL_SOCKET, SO_RCVBUF, |
134 | @@ -1533,13 +1562,17 @@ | 134 | @@ -1535,13 +1564,17 @@ |
135 | } | 135 | } |
136 | 136 | ||
137 | if (minttl != -1) { | 137 | if (minttl != -1) { |
@@ -150,7 +150,7 @@ | |||
150 | } | 150 | } |
151 | } | 151 | } |
152 | 152 | ||
153 | @@ -1761,14 +1794,22 @@ | 153 | @@ -1763,14 +1796,22 @@ |
154 | \t-P proxyuser\tUsername for proxy authentication\n\ | 154 | \t-P proxyuser\tUsername for proxy authentication\n\ |
155 | \t-p port\t Specify local port for remote connects\n\ | 155 | \t-p port\t Specify local port for remote connects\n\ |
156 | \t-R CAfile CA bundle\n\ | 156 | \t-R CAfile CA bundle\n\ |