From 0150c6e83d24cf5511f58353c2bdc9b1509c0eea Mon Sep 17 00:00:00 2001
From: Dima Dorfman
Date: Tue, 22 May 2001 22:16:18 +0000
Subject: [PATCH] Unifdef DEV_SNP; snp(4) no longer requires these ugly hacks.
Silence by: -hackers, -audit
---
sys/kern/tty.c | 27 ---------------------------
1 file changed, 27 deletions(-)
diff --git a/sys/kern/tty.c b/sys/kern/tty.c
index ee152b7e6055..4086acd40626 100644
--- a/sys/kern/tty.c
+++ b/sys/kern/tty.c
@@ -67,7 +67,6 @@
* only when _all_ openers leave open().
*/
-#include "opt_snp.h"
#include "opt_compat.h"
#include "opt_uconsole.h"
@@ -93,9 +92,6 @@
#include
#include
#include
-#ifdef DEV_SNP
-#include
-#endif
#include
#include
@@ -259,11 +255,6 @@ ttyclose(tp)
clist_free_cblocks(&tp->t_outq);
clist_free_cblocks(&tp->t_rawq);
-#ifdef DEV_SNP
- if (ISSET(tp->t_state, TS_SNOOP) && tp->t_sc != NULL)
- snpdown((struct snoop *)tp->t_sc);
-#endif
-
tp->t_gen++;
tp->t_line = TTYDISC;
tp->t_pgrp = NULL;
@@ -1716,11 +1707,6 @@ ttread(tp, uio, flag)
* XXX if there was an error then we should ungetc() the
* unmoved chars and reduce icc here.
*/
-#ifdef DEV_SNP
- if (ISSET(tp->t_lflag, ECHO) &&
- ISSET(tp->t_state, TS_SNOOP) && tp->t_sc != NULL)
- snpin((struct snoop *)tp->t_sc, ibuf, icc);
-#endif
if (error)
break;
if (uio->uio_resid == 0)
@@ -1763,15 +1749,6 @@ ttread(tp, uio, flag)
if (error)
/* XXX should ungetc(c, qp). */
break;
-#ifdef DEV_SNP
- /*
- * Only snoop directly on input in echo mode. Non-echoed
- * input will be snooped later iff the application echoes it.
- */
- if (ISSET(tp->t_lflag, ECHO) &&
- ISSET(tp->t_state, TS_SNOOP) && tp->t_sc != NULL)
- snpinc((struct snoop *)tp->t_sc, (char)c);
-#endif
if (uio->uio_resid == 0)
break;
/*
@@ -1916,10 +1893,6 @@ ttwrite(tp, uio, flag)
cc = 0;
break;
}
-#ifdef DEV_SNP
- if (ISSET(tp->t_state, TS_SNOOP) && tp->t_sc != NULL)
- snpin((struct snoop *)tp->t_sc, cp, cc);
-#endif
}
/*
* If nothing fancy need be done, grab those characters we