freebsd-dev/sbin/restore
Ian Dowse cfd8a00918 In createfiles(), properly handle a number of cases where no further
volumes are available, instead of getting stuck in a loop calling
getvol(). Normally restore in 'x' or 'i' modes will ask for a new
(earlier) volume when the current inode number on the tape is greater
than the last inode to be restored, since there can be no further
inodes of interest on that volume. However we don't want to change
volumes in this case either if the user explicitly said that there
are no more tapes, or if we are looking at the first volume.

When no more volumes are available but there are still inodes that
we have not found, we now just fall through to the code that prints
out a list of any missing files, so the restore completes normally.
Also simplify the logic a bit by always returning to the start of
the main for(;;) loop whenever the volume has changed.

This should completely fix the "Changing volumes on pipe input" bug
that is often observed when restoring dumps of active filesystems.

PR:		bin/4176, bin/34604, misc/34675
2002-02-14 01:30:45 +00:00
..
dirs.c Respect the -N flag when changing directory attributes in setdirmode). 2001-08-20 02:15:22 +00:00
extern.h Silence non-constant format string warnings by marking functions 2001-08-19 08:19:37 +00:00
interactive.c Stop restore from looping under certain error conditions. This 2000-12-12 12:04:02 +00:00
main.c Documentation fixes: 2001-10-02 08:24:37 +00:00
Makefile Default to WARNS=2. 2001-12-04 02:19:58 +00:00
restore.8 Documentation fixes: 2001-10-02 08:24:37 +00:00
restore.c In createfiles(), properly handle a number of cases where no further 2002-02-14 01:30:45 +00:00
restore.h Well, nobody objected, so here's my -u (unlink) flag to restore. 1998-05-09 05:23:02 +00:00
symtab.c Fix a bug where restore(8) segfaults while trying to restore on a 2001-10-30 20:06:59 +00:00
tape.c Fix a number of long-standing restore bugs in tape.c, mainly relating 2002-02-13 12:06:58 +00:00
utilities.c Include missing header files which define functions for which gcc has 2001-06-24 23:04:23 +00:00