summaryrefslogtreecommitdiff
path: root/sbin/slattach
diff options
context:
space:
mode:
authorfair <fair@NetBSD.org>1998-03-23 04:41:16 +0000
committerfair <fair@NetBSD.org>1998-03-23 04:41:16 +0000
commit782eb42847d08348d2a18742992c6a56d7c8ba1f (patch)
treedf0d73e5c602a2ad4ea1e1e2d3c1a49dc3147c31 /sbin/slattach
parent2c299cbd5cc2787e2690b80baa5a179ec5ce634b (diff)
add the ability to run SLIP with CLOCAL set, per PR#3586
Diffstat (limited to 'sbin/slattach')
-rw-r--r--sbin/slattach/slattach.85
-rw-r--r--sbin/slattach/slattach.c11
2 files changed, 11 insertions, 5 deletions
diff --git a/sbin/slattach/slattach.8 b/sbin/slattach/slattach.8
index c0b3600caf3..49fd8c03904 100644
--- a/sbin/slattach/slattach.8
+++ b/sbin/slattach/slattach.8
@@ -1,4 +1,4 @@
-.\" $NetBSD: slattach.8,v 1.18 1997/12/04 22:33:52 msaitoh Exp $
+.\" $NetBSD: slattach.8,v 1.19 1998/03/23 04:41:16 fair Exp $
.\"
.\" Copyright (c) 1986, 1991, 1993
.\" The Regents of the University of California. All rights reserved.
@@ -57,6 +57,9 @@ The following operands are supported by
Turn on RTS/CTS flow control. By default, no flow control is done.
.It Fl H
Turn on DTR/CTS flow control. By default, no flow control is done.
+.It Fl l
+Turn on the CLOCAL flag, making it possible to run SLIP on a cable
+without modem control signals (e.g. DTR, DSR, DCD).
.It Fl m
Maintain modem control signals after closing the line. Specifically,
this disables HUPCL.
diff --git a/sbin/slattach/slattach.c b/sbin/slattach/slattach.c
index 915f89bd8a3..667fdc27563 100644
--- a/sbin/slattach/slattach.c
+++ b/sbin/slattach/slattach.c
@@ -1,4 +1,4 @@
-/* $NetBSD: slattach.c,v 1.20 1997/11/17 23:15:12 thorpej Exp $ */
+/* $NetBSD: slattach.c,v 1.21 1998/03/23 04:41:16 fair Exp $ */
/*
* Copyright (c) 1988, 1993
@@ -46,7 +46,7 @@ __COPYRIGHT("@(#) Copyright (c) 1988, 1993\n\
#if 0
static char sccsid[] = "@(#)slattach.c 8.2 (Berkeley) 1/7/94";
#else
-__RCSID("$NetBSD: slattach.c,v 1.20 1997/11/17 23:15:12 thorpej Exp $");
+__RCSID("$NetBSD: slattach.c,v 1.21 1998/03/23 04:41:16 fair Exp $");
#endif
#endif /* not lint */
@@ -91,7 +91,7 @@ main(argc, argv)
int ch;
sigset_t sigset;
- while ((ch = getopt(argc, argv, "hHms:t:")) != -1) {
+ while ((ch = getopt(argc, argv, "hHlms:t:")) != -1) {
switch (ch) {
case 'h':
cflag |= CRTSCTS;
@@ -99,6 +99,9 @@ main(argc, argv)
case 'H':
cflag |= CDTRCTS;
break;
+ case 'l':
+ cflag |= CLOCAL;
+ break;
case 'm':
cflag &= ~HUPCL;
break;
@@ -172,7 +175,7 @@ usage()
extern char *__progname;
(void)fprintf(stderr,
- "usage: %s [-t ldisc] [-hm] [-s baudrate] ttyname\n",
+ "usage: %s [-t ldisc] [-hHlm] [-s baudrate] ttyname\n",
__progname);
exit(1);
}