diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1998-07-16 22:31:15 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1998-07-16 22:31:15 +0000 |
commit | 770ee673a0df4166e4bfff667d7e4297e3768ea9 (patch) | |
tree | 66afb5b32d14575d98dc23c075c7f93a220f2814 /bin/mt | |
parent | 54778bd7b0574ec289a7f51af218a5701bee9d6a (diff) |
support scsi better; fix another weird bug; mjacob
Diffstat (limited to 'bin/mt')
-rw-r--r-- | bin/mt/mt.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/bin/mt/mt.c b/bin/mt/mt.c index f1eaad9893a..201c8a28f33 100644 --- a/bin/mt/mt.c +++ b/bin/mt/mt.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mt.c,v 1.17 1997/04/16 04:19:07 millert Exp $ */ +/* $OpenBSD: mt.c,v 1.18 1998/07/16 22:31:14 deraadt Exp $ */ /* $NetBSD: mt.c,v 1.14.2.1 1996/05/27 15:12:11 mrg Exp $ */ /* @@ -44,7 +44,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)mt.c 8.2 (Berkeley) 6/6/93"; #else -static char rcsid[] = "$OpenBSD: mt.c,v 1.17 1997/04/16 04:19:07 millert Exp $"; +static char rcsid[] = "$OpenBSD: mt.c,v 1.18 1998/07/16 22:31:14 deraadt Exp $"; #endif #endif /* not lint */ @@ -234,7 +234,8 @@ struct tape_desc { #ifdef tahoe { MT_ISCY, "cipher", CYS_BITS, CYCW_BITS }, #endif - { 0x7, "SCSI", "76543210", "76543210" }, +#define SCSI_DS_BITS "\20\5WriteProtect\2Mounted" + { 0x7, "SCSI", SCSI_DS_BITS, "76543210" }, { 0 } }; @@ -287,7 +288,7 @@ printreg(s, v, bits) if (!bits) return; bits++; - if (v && bits) { + if (v && *bits) { putchar('<'); while ((i = *bits++)) { if (v & (1 << (i-1))) { |