X-Git-Url: https://git.wh0rd.org/?a=blobdiff_plain;f=restore%2Ftape.c;h=8665e550cc174b56e641a08ec0546f730d05e288;hb=42bcc624fe21059d5e550e90befb3553c17e2858;hp=f59fc02b4770e7846e66cc449c7a3f9582cb59af;hpb=d8574d458324cdde27484485cb09e7c9b8fa1a77;p=dump.git diff --git a/restore/tape.c b/restore/tape.c index f59fc02..8665e55 100644 --- a/restore/tape.c +++ b/restore/tape.c @@ -2,7 +2,8 @@ * Ported to Linux's Second Extended File System as part of the * dump and restore backup suit * Remy Card , 1994-1997 - * Stelian Pop , 1999-2000 + * Stelian Pop , 1999-2000 + * Stelian Pop - AlcĂ´ve , 2000 */ /* @@ -45,7 +46,7 @@ #ifndef lint static const char rcsid[] = - "$Id: tape.c,v 1.16 2000/06/01 18:30:08 stelian Exp $"; + "$Id: tape.c,v 1.21 2000/12/04 15:43:17 stelian Exp $"; #endif /* not lint */ #include @@ -279,7 +280,7 @@ setup(void) Dprintf(stdout, "maxino = %ld\n", (long)maxino); map = calloc((unsigned)1, (unsigned)howmany(maxino, NBBY)); if (map == NULL) - panic("no memory for active inode map\n"); + errx(1, "no memory for active inode map"); usedinomap = map; curfile.action = USING; getfile(xtrmap, xtrmapskip); @@ -287,7 +288,7 @@ setup(void) errx(1, "Cannot find file dump list"); map = calloc((unsigned)1, (unsigned)howmany(maxino, NBBY)); if (map == (char *)NULL) - panic("no memory for file dump list\n"); + errx(1, "no memory for file dump list"); dumpmap = map; curfile.action = USING; getfile(xtrmap, xtrmapskip); @@ -359,7 +360,7 @@ again: do { fprintf(stderr, "Specify next volume #: "); (void) fflush(stderr); - (void) fgets(buf, BUFSIZ, terminal); + (void) fgets(buf, TP_BSIZE, terminal); } while (!feof(terminal) && buf[0] == '\n'); if (feof(terminal)) exit(1); @@ -384,7 +385,7 @@ again: fprintf(stderr, "Enter ``none'' if there are no more tapes\n"); fprintf(stderr, "otherwise enter tape name (default: %s) ", magtape); (void) fflush(stderr); - (void) fgets(buf, BUFSIZ, terminal); + (void) fgets(buf, TP_BSIZE, terminal); if (feof(terminal)) exit(1); if (!strcmp(buf, "none\n")) { @@ -546,9 +547,9 @@ printdumpinfo(void) #endif if (spcl.c_host[0] == '\0') return; - fprintf(stderr, "Level %d dump of %s on %s:%s\n", + fprintf(stdout, "Level %d dump of %s on %s:%s\n", spcl.c_level, spcl.c_filesys, spcl.c_host, spcl.c_dev); - fprintf(stderr, "Label: %s\n", spcl.c_label); + fprintf(stdout, "Label: %s\n", spcl.c_label); } int