diff options
author | jkh <jkh@FreeBSD.org> | 1998-03-23 23:19:14 +0000 |
---|---|---|
committer | jkh <jkh@FreeBSD.org> | 1998-03-23 23:19:14 +0000 |
commit | 16c0eec42886c598c2233d0bfdfb078aaabd29d4 (patch) | |
tree | 2bbe4997c4054acaf38dc69637cbe6cbd4bae0a3 /sbin/restore | |
parent | fc17422716085798304a839f7ea7107713c57946 (diff) | |
download | FreeBSD-src-16c0eec42886c598c2233d0bfdfb078aaabd29d4.zip FreeBSD-src-16c0eec42886c598c2233d0bfdfb078aaabd29d4.tar.gz |
The logic in tape.c:getfile() doesn't allow for a filesystem
with a blocksize smaller than the tape block size. The problem
seems to be most easily fixed by changeing where fssize is set.
PR: 5704
Submitted by: David Malone <dwmalone@maths.tcd.ie>
Diffstat (limited to 'sbin/restore')
-rw-r--r-- | sbin/restore/tape.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sbin/restore/tape.c b/sbin/restore/tape.c index 5da5c93..204d736 100644 --- a/sbin/restore/tape.c +++ b/sbin/restore/tape.c @@ -231,7 +231,9 @@ setup() fprintf(stderr, "cannot stat .: %s\n", strerror(errno)); done(1); } - if (stbuf.st_blksize > 0 && stbuf.st_blksize <= MAXBSIZE) + if (stbuf.st_blksize > 0 && stbuf.st_blksize < TP_BSIZE ) + fssize = TP_BSIZE; + if (stbuf.st_blksize >= TP_BSIZE && stbuf.st_blksize <= MAXBSIZE) fssize = stbuf.st_blksize; if (((fssize - 1) & fssize) != 0) { fprintf(stderr, "bad block size %d\n", fssize); |