diff options
author | bde <bde@FreeBSD.org> | 1995-10-21 08:51:01 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 1995-10-21 08:51:01 +0000 |
commit | c529f03691795a7fff7b8d7a54fe64dc722f7012 (patch) | |
tree | b57ad601e128a329a5ac9b173905c08a4c1299fa /usr.bin | |
parent | 50bd49a6eddb182f85a73a737d18da26fc5acdc1 (diff) | |
download | FreeBSD-src-c529f03691795a7fff7b8d7a54fe64dc722f7012.zip FreeBSD-src-c529f03691795a7fff7b8d7a54fe64dc722f7012.tar.gz |
Return early in printreg() when the pointer is NULL. For FreeBSD, the
strings describing the drive status and error bits are so deficient
that the pointer is always NULL.
Reported by: Philippe Charnier <charnier@lirmm.fr>
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/mt/mt.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/usr.bin/mt/mt.c b/usr.bin/mt/mt.c index 2aab88b..81bdefb 100644 --- a/usr.bin/mt/mt.c +++ b/usr.bin/mt/mt.c @@ -302,6 +302,8 @@ printreg(s, v, bits) printf("%s=%o", s, v); else printf("%s=%x", s, v); + if (!bits) + return; bits++; if (v && bits) { putchar('<'); |