From 563f9088bed943b10ef16039fbe5a6512ac0a99b Mon Sep 17 00:00:00 2001 From: phk Date: Mon, 10 May 1999 18:10:08 +0000 Subject: Use NODEV instead of -1 --- sys/dev/snp/snp.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'sys/dev/snp') diff --git a/sys/dev/snp/snp.c b/sys/dev/snp/snp.c index 204088c..1018083 100644 --- a/sys/dev/snp/snp.c +++ b/sys/dev/snp/snp.c @@ -317,7 +317,7 @@ snpopen(dev, flag, mode, p) * snp_tty == NULL is for inactive snoop devices. */ snp->snp_tty = NULL; - snp->snp_target = -1; + snp->snp_target = NODEV; return (0); } @@ -349,7 +349,7 @@ snp_detach(snp) printf("Snoop: bad attached tty data.\n"); snp->snp_tty = NULL; - snp->snp_target = -1; + snp->snp_target = NODEV; detach_notty: selwakeup(&snp->snp_sel); @@ -404,7 +404,7 @@ snpioctl(dev, cmd, data, flags, p) switch (cmd) { case SNPSTTY: tdev = *((dev_t *) data); - if (tdev == -1) + if (tdev == NODEV) return (snpdown(snp)); tp = snpdevtotty(tdev); @@ -419,7 +419,7 @@ snpioctl(dev, cmd, data, flags, p) s = spltty(); - if (snp->snp_target == -1) { + if (snp->snp_target == NODEV) { tpo = snp->snp_tty; if (tpo) tpo->t_state &= ~TS_SNOOP; -- cgit v1.1