From 700291efee9ad83d41274411f663a896bc1c110a Mon Sep 17 00:00:00 2001 From: Maxim Sobolev Date: Wed, 18 Apr 2001 15:32:59 +0000 Subject: Add tits 1.0.2, a server which provides telnet(1) access to one or more tty ports. Obtained from: NetBSD --- comms/tits/files/patch-Makefile | 20 ++++++++++++++++++++ comms/tits/files/patch-dispatcher.h | 14 ++++++++++++++ comms/tits/files/patch-tty.c | 23 +++++++++++++++++++++++ 3 files changed, 57 insertions(+) create mode 100644 comms/tits/files/patch-Makefile create mode 100644 comms/tits/files/patch-dispatcher.h create mode 100644 comms/tits/files/patch-tty.c (limited to 'comms/tits/files') diff --git a/comms/tits/files/patch-Makefile b/comms/tits/files/patch-Makefile new file mode 100644 index 000000000000..9a6d57db914a --- /dev/null +++ b/comms/tits/files/patch-Makefile @@ -0,0 +1,20 @@ + +$FreeBSD$ + +--- Makefile.orig Tue Feb 20 22:27:21 2001 ++++ Makefile Wed Apr 18 18:29:23 2001 +@@ -32,12 +32,12 @@ + WARNS= 2 + + PROG= tits +-MAN= tits.8 ++MAN8= tits.8 + + SRCS= main.c buffer.c client.c context.c listener.c telnet.c tty.c + SRCS+= dispatcher.c setup.c config.c server.c logger.c + +-CPPFLAGS+= -DLIBWRAP -DTITS_DEFAULT_CONFIG_FILE=\"${LOCALBASE}/etc/tits.conf\" ++CFLAGS+= -DLIBWRAP -DTITS_DEFAULT_CONFIG_FILE=\"${LOCALBASE}/etc/tits.conf\" + LDADD+= -lwrap + PREFIX?= /usr/local + BINDIR?= ${PREFIX}/sbin diff --git a/comms/tits/files/patch-dispatcher.h b/comms/tits/files/patch-dispatcher.h new file mode 100644 index 000000000000..cbf7fc094f04 --- /dev/null +++ b/comms/tits/files/patch-dispatcher.h @@ -0,0 +1,14 @@ + +$FreeBSD$ + +--- dispatcher.h 2001/04/18 14:50:37 1.1 ++++ dispatcher.h 2001/04/18 14:51:57 +@@ -43,4 +43,8 @@ + extern void dispatcher_del_client(struct client_ctx *); + extern int dispatcher_mainloop(void); + ++#ifdef __FreeBSD__ ++typedef unsigned int nfds_t; ++#endif ++ + #endif /* __dispatcher_h */ diff --git a/comms/tits/files/patch-tty.c b/comms/tits/files/patch-tty.c new file mode 100644 index 000000000000..3d7ba33635b6 --- /dev/null +++ b/comms/tits/files/patch-tty.c @@ -0,0 +1,23 @@ + +$FreeBSD$ + +--- tty.c 2001/04/18 14:43:52 1.1 ++++ tty.c 2001/04/18 14:45:57 +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + #include + + #include +@@ -216,8 +217,7 @@ + * If this is *not* a pseudo tty, ensure DTR is asserted. + * Note: This relies on TIOCGFLAGS returning ENOTTY for pty(4)'s. + */ +- if (ioctl(cc->cc_fd, TIOCGFLAGS, &flags) == 0 && errno == ENOTTY && +- ioctl(cc->cc_fd, TIOCSDTR, 0) < 0) { ++ if (ioctl(cc->cc_fd, TIOCSDTR, 0) < 0 && errno != ENOTTY) { + (void) close(cc->cc_fd); + (void) free(tc->tc_to.to_device); + (void) free(tc); -- cgit v1.2.3