Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/nc Skip options which rely on crypto support in geto...



details:   https://anonhg.NetBSD.org/src/rev/360a5328b285
branches:  trunk
changeset: 459957:360a5328b285
user:      sevan <sevan%NetBSD.org@localhost>
date:      Thu Oct 03 01:15:19 2019 +0000

description:
Skip options which rely on crypto support in getopt() argument list, if we're
not building with cryto support.

via JP <rlntlss83 at gmail com> on tech-misc@

diffstat:

 usr.bin/nc/netcat.c |  9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r 3a2ceddfae1f -r 360a5328b285 usr.bin/nc/netcat.c
--- a/usr.bin/nc/netcat.c       Thu Oct 03 00:59:49 2019 +0000
+++ b/usr.bin/nc/netcat.c       Thu Oct 03 01:15:19 2019 +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.5 2017/02/09 21:23:48 christos Exp $");
+__RCSID("$NetBSD: netcat.c,v 1.6 2019/10/03 01:15:19 sevan Exp $");
 
 /*
  * Re-written nc(1) for OpenBSD. Original implementation by
@@ -180,7 +180,12 @@
        signal(SIGPIPE, SIG_IGN);
 
        while ((ch = getopt(argc, argv,
-           "46C:cDde:FH:hI:i:K:klM:m:NnO:o:P:p:R:rSs:T:tUuV:vw:X:x:z")) != -1) {
+#ifdef CRYPTO
+           "46C:cDde:FH:hI:i:K:klM:m:NnO:o:P:p:R:rSs:T:tUuV:vw:X:x:z"
+#else
+           "46Dde:FhI:i:klM:m:NnO:P:p:rSs:tUuvw:X:x:z"
+#endif
+       )) != -1) {
                switch (ch) {
                case '4':
                        family = AF_INET;



Home | Main Index | Thread Index | Old Index