summaryrefslogtreecommitdiffstats
path: root/sbin/restore
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2005-03-25 06:57:50 +0000
committerimp <imp@FreeBSD.org>2005-03-25 06:57:50 +0000
commit490dc8aaa3f8ff1dd78d580d1061fc349896e689 (patch)
treec31b18cab1ad8fb73df374b88fa3bc8b51c7ebe2 /sbin/restore
parentd00974ed1109ec8b1e2e988ab6e318f716459273 (diff)
downloadFreeBSD-src-490dc8aaa3f8ff1dd78d580d1061fc349896e689.zip
FreeBSD-src-490dc8aaa3f8ff1dd78d580d1061fc349896e689.tar.gz
dcvt is unused since the support for converting pre-4.4 tapes was
removed. Go ahead and remove it and struct odirent since it too is unused. # FreeBSD 1.1.5 tapes are still unreadable, but 2.0 and newer work.
Diffstat (limited to 'sbin/restore')
-rw-r--r--sbin/restore/Makefile1
-rw-r--r--sbin/restore/dirs.c27
2 files changed, 3 insertions, 25 deletions
diff --git a/sbin/restore/Makefile b/sbin/restore/Makefile
index c06a3db..266a5de 100644
--- a/sbin/restore/Makefile
+++ b/sbin/restore/Makefile
@@ -6,6 +6,7 @@
PROG= restore
LINKS= ${BINDIR}/restore ${BINDIR}/rrestore
CFLAGS+=-DRRESTORE
+CFLAGS+=-g
WARNS?= 0
SRCS= main.c interactive.c restore.c dirs.c symtab.c tape.c utilities.c \
dumprmt.c
diff --git a/sbin/restore/dirs.c b/sbin/restore/dirs.c
index 327d3ed..ee37113 100644
--- a/sbin/restore/dirs.c
+++ b/sbin/restore/dirs.c
@@ -109,17 +109,7 @@ static char dirfile[MAXPATHLEN] = "#"; /* No file */
static char modefile[MAXPATHLEN] = "#"; /* No file */
static char dot[2] = "."; /* So it can be modified */
-/*
- * Format of old style directories.
- */
-#define ODIRSIZ 14
-struct odirect {
- u_short d_ino;
- char d_name[ODIRSIZ];
-};
-
static struct inotab *allocinotab(struct context *, long);
-static void dcvt(struct odirect *, struct direct *);
static void flushent(void);
static struct inotab *inotablookup(ino_t);
static RST_DIR *opendirfile(const char *);
@@ -288,6 +278,8 @@ pathsearch(const char *pathname)
struct direct *dp;
char *path, *name, buffer[MAXPATHLEN];
+ printf("Looking for %s\n", pathname);
+
strcpy(buffer, pathname);
path = buffer;
ino = ROOTINO;
@@ -332,9 +324,6 @@ searchdir(ino_t inum, char *name)
static void
putdir(char *buf, long size)
{
- struct direct cvtbuf;
- struct odirect *odp;
- struct odirect *eodp;
struct direct *dp;
long loc, i;
@@ -412,18 +401,6 @@ flushent(void)
dirloc = 0;
}
-static void
-dcvt(struct odirect *odp, struct direct *ndp)
-{
-
- memset(ndp, 0, (long)(sizeof *ndp));
- ndp->d_ino = odp->d_ino;
- ndp->d_type = DT_UNKNOWN;
- (void) strncpy(ndp->d_name, odp->d_name, ODIRSIZ);
- ndp->d_namlen = strlen(ndp->d_name);
- ndp->d_reclen = DIRSIZ(0, ndp);
-}
-
/*
* Seek to an entry in a directory.
* Only values returned by rst_telldir should be passed to rst_seekdir.
OpenPOWER on IntegriCloud