From 5d2a3d246d400d45dfd4c49ddb588c69fb60873d Mon Sep 17 00:00:00 2001 From: Stelian Pop Date: Fri, 25 Jan 2002 15:08:59 +0000 Subject: [PATCH] kill "register". --- common/dumprmt.c | 18 +++++++++--------- compat/lib/compatglob.c | 20 ++++++++++---------- compat/lib/fstab.c | 4 ++-- dump/itime.c | 14 +++++++------- dump/main.c | 16 ++++++++-------- dump/optr.c | 16 ++++++++-------- dump/tape.c | 14 +++++++------- dump/traverse.c | 30 +++++++++++++++--------------- dump/unctime.c | 4 ++-- restore/dirs.c | 32 ++++++++++++++++---------------- restore/interactive.c | 18 +++++++++--------- restore/restore.c | 32 ++++++++++++++++---------------- restore/symtab.c | 26 +++++++++++++------------- restore/tape.c | 6 +++--- restore/utilities.c | 8 ++++---- 15 files changed, 129 insertions(+), 129 deletions(-) diff --git a/common/dumprmt.c b/common/dumprmt.c index 4c1bedf..4d570fd 100644 --- a/common/dumprmt.c +++ b/common/dumprmt.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: dumprmt.c,v 1.19 2002/01/16 09:32:14 stelian Exp $"; + "$Id: dumprmt.c,v 1.20 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -161,8 +161,8 @@ rmtconnaborted(int signo) static int rmtgetconn(void) { - register char *cp; - register const char *rmt; + char *cp; + const char *rmt; static struct servent *sp = NULL; static struct passwd *pwd = NULL; const char *tuser; @@ -259,8 +259,8 @@ rmtgetconn(void) static int okname(const char *cp0) { - register const char *cp; - register int c; + const char *cp; + int c; for (cp = cp0; *cp; cp++) { c = *cp; @@ -337,8 +337,8 @@ struct mtget mts; struct mtget * rmtstatus(void) { - register int i; - register char *cp; + int i; + char *cp; if (rmtstate != TS_OPEN) return (NULL); @@ -371,7 +371,7 @@ rmtcall(const char *cmd, const char *buf) static int rmtreply(const char *cmd) { - register char *cp; + char *cp; char code[30], emsg[BUFSIZ]; rmtgets(code, sizeof (code)); @@ -410,7 +410,7 @@ rmtgetb(void) static void rmtgets(char *line, size_t len) { - register char *cp = line; + char *cp = line; while (len > 1) { *cp = rmtgetb(); diff --git a/compat/lib/compatglob.c b/compat/lib/compatglob.c index 4b70101..23fc61c 100644 --- a/compat/lib/compatglob.c +++ b/compat/lib/compatglob.c @@ -69,7 +69,7 @@ #ifndef lint static const char rcsid[] = - "$Id: compatglob.c,v 1.7 2002/01/16 09:32:14 stelian Exp $"; + "$Id: compatglob.c,v 1.8 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -564,7 +564,7 @@ glob2(Char *pathbuf, Char *pathend, Char *pattern, glob_t *pglob) static int glob3(Char *pathbuf, Char *pathend, Char *pattern, Char *restpattern, glob_t *pglob) { - register struct dirent *dp; + struct dirent *dp; DIR *dirp; int err; char buf[MAXPATHLEN]; @@ -599,8 +599,8 @@ glob3(Char *pathbuf, Char *pathend, Char *pattern, Char *restpattern, glob_t *pg else readdirfunc = readdir; while ((dp = (*readdirfunc)(dirp))) { - register u_char *sc; - register Char *dc; + u_char *sc; + Char *dc; /* Initial DOT must be matched literally. */ if (dp->d_name[0] == DOT && *pattern != DOT) @@ -642,8 +642,8 @@ glob3(Char *pathbuf, Char *pathend, Char *pattern, Char *restpattern, glob_t *pg static int globextend(const Char *path, glob_t *pglob) { - register char **pathv; - register int i; + char **pathv; + int i; u_int newsize; char *copy; const Char *p; @@ -727,8 +727,8 @@ match(Char *name, Char *pat, Char *patend) void globfree(glob_t *pglob) { - register int i; - register char **pp; + int i; + char **pp; if (pglob->gl_pathv != NULL) { pp = pglob->gl_pathv + pglob->gl_offs; @@ -806,7 +806,7 @@ g_strcat(Char *dst, const Char *src) static void g_Ctoc(const Char *str, char *buf) { - register char *dc; + char *dc; for (dc = buf; (*dc++ = *str++) != EOS;) continue; @@ -816,7 +816,7 @@ g_Ctoc(const Char *str, char *buf) static void qprintf(const char *str, Char *s) { - register Char *p; + Char *p; (void)printf("%s:\n", str); for (p = s; *p; p++) diff --git a/compat/lib/fstab.c b/compat/lib/fstab.c index 2a601d5..de95455 100644 --- a/compat/lib/fstab.c +++ b/compat/lib/fstab.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: fstab.c,v 1.12 2002/01/16 09:32:14 stelian Exp $"; + "$Id: fstab.c,v 1.13 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -66,7 +66,7 @@ static int fstabscan(void) { struct mntent *mnt; - register char *cp; + char *cp; int typexx; #define MAXLINELENGTH 1024 char subline[MAXLINELENGTH]; diff --git a/dump/itime.c b/dump/itime.c index da968db..204fc58 100644 --- a/dump/itime.c +++ b/dump/itime.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: itime.c,v 1.21 2002/01/16 09:32:14 stelian Exp $"; + "$Id: itime.c,v 1.22 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -131,8 +131,8 @@ initdumptimes(int createdumpdates) static void readdumptimes(FILE *df) { - register int i; - register struct dumptime *dtwalk; + int i; + struct dumptime *dtwalk; for (;;) { dtwalk = (struct dumptime *)calloc(1, sizeof (struct dumptime)); @@ -158,8 +158,8 @@ readdumptimes(FILE *df) void getdumptime(int createdumpdates) { - register struct dumpdates *ddp; - register int i; + struct dumpdates *ddp; + int i; #ifdef FDEBUG msg("Looking for name %s in dumpdates = %s for level = %c\n", @@ -197,8 +197,8 @@ void putdumptime(void) { FILE *df; - register struct dumpdates *dtwalk; - register int i; + struct dumpdates *dtwalk; + int i; int fd; if(uflag == 0) diff --git a/dump/main.c b/dump/main.c index ac6a7a1..6ac72ee 100644 --- a/dump/main.c +++ b/dump/main.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: main.c,v 1.67 2002/01/25 14:59:53 stelian Exp $"; + "$Id: main.c,v 1.68 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -192,12 +192,12 @@ static int iexclude_num = 0; /* number of elements in the list */ int main(int argc, char *argv[]) { - register dump_ino_t ino; - register int dirty; - register struct dinode *dp; - register struct fstab *dt; - register char *map; - register int ch; + dump_ino_t ino; + int dirty; + struct dinode *dp; + struct fstab *dt; + char *map; + int ch; int i, anydirskipped; int aflag = 0, bflag = 0, Tflag = 0, honorlevel = 1; dump_ino_t maxino; @@ -210,7 +210,7 @@ main(int argc, char *argv[]) #endif time_t tnow; char *diskparam; - char *Apath; + char *Apath = NULL; spcl.c_label[0] = '\0'; spcl.c_date = time(NULL); diff --git a/dump/optr.c b/dump/optr.c index 73347fa..a580f35 100644 --- a/dump/optr.c +++ b/dump/optr.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: optr.c,v 1.29 2002/01/16 09:32:14 stelian Exp $"; + "$Id: optr.c,v 1.30 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -285,7 +285,7 @@ static void sendmes(const char *tty, const char *message) { char t[MAXPATHLEN], buf[BUFSIZ]; - register const char *cp; + const char *cp; int lmsg = 1; FILE *f_tty; @@ -426,7 +426,7 @@ quit(fmt, va_alist) static struct fstab * allocfsent(struct fstab *fs) { - register struct fstab *new; + struct fstab *new; new = (struct fstab *)malloc(sizeof (*fs)); if (new == NULL) @@ -499,8 +499,8 @@ getfstab(void) struct fstab * fstabsearch(const char *key) { - register struct pfstab *pf; - register struct fstab *fs; + struct pfstab *pf; + struct fstab *fs; const char *rn; for (pf = table; pf != NULL; pf = pf->pf_next) { @@ -527,9 +527,9 @@ fstabsearch(const char *key) struct fstab * fstabsearchdir(const char *key, char *directory) { - register struct pfstab *pf; - register struct fstab *fs; - register struct fstab *found_fs = NULL; + struct pfstab *pf; + struct fstab *fs; + struct fstab *found_fs = NULL; unsigned int size = 0; struct stat buf; diff --git a/dump/tape.c b/dump/tape.c index 66fc821..5fa739c 100644 --- a/dump/tape.c +++ b/dump/tape.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: tape.c,v 1.61 2002/01/25 14:59:53 stelian Exp $"; + "$Id: tape.c,v 1.62 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -593,8 +593,8 @@ close_rewind(void) void rollforward(void) { - register struct req *p, *q = NULL, *prev; - register struct slave *tslp; + struct req *p, *q = NULL, *prev; + struct slave *tslp; int i, size, savedtapea, got; union u_spcl *ntb, *otb; struct slave_results returned; @@ -966,7 +966,7 @@ enslave(void) #ifdef LINUX_FORK_BUG int i, j; #else - register int i, j; + int i, j; #endif master = getpid(); @@ -1042,7 +1042,7 @@ enslave(void) void killall(void) { - register int i; + int i; for (i = 0; i < SLAVES; i++) if (slaves[i].pid > 0) { @@ -1061,7 +1061,7 @@ killall(void) static void doslave(int cmd, int slave_number, int first) { - register int nread; + int nread; int nextslave, size, eot_count, bufsize; volatile int wrote = 0; char *buffer; @@ -1130,7 +1130,7 @@ doslave(int cmd, int slave_number, int first) * Get list of blocks to dump, read the blocks into tape buffer */ while ((nread = atomic_read( cmd, (char *)slp->req, reqsiz)) == reqsiz) { - register struct req *p = slp->req; + struct req *p = slp->req; for (trecno = 0; trecno < ntrec; trecno += p->count, p += p->count) { diff --git a/dump/traverse.c b/dump/traverse.c index 80d7e86..147717a 100644 --- a/dump/traverse.c +++ b/dump/traverse.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: traverse.c,v 1.41 2002/01/25 14:59:53 stelian Exp $"; + "$Id: traverse.c,v 1.42 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -241,7 +241,7 @@ blockest(struct dinode const *dp) static void mapfileino(dump_ino_t ino, struct dinode const *dp, long *tapesize, int *dirskipped) { - register int mode; + int mode; /* * Skip inode if we've already marked it for dumping @@ -335,7 +335,7 @@ mapfiles(dump_ino_t maxino, long *tapesize) int mapfiles(dump_ino_t maxino, long *tapesize) { - register dump_ino_t ino; + dump_ino_t ino; int anydirskipped = 0; for (ino = ROOTINO; ino < maxino; ino++) @@ -407,8 +407,8 @@ struct mapfile_context { static int mapfilesindir(struct ext2_dir_entry *dirent, int offset, int blocksize, char *buf, void *private) { - register struct dinode const *dp; - register int mode; + struct dinode const *dp; + int mode; errcode_t retval; struct mapfile_context *mfc; ext2_ino_t ino; @@ -522,12 +522,12 @@ struct mapdirs_context { int mapdirs(dump_ino_t maxino, long *tapesize) { - register struct dinode *dp; - register int isdir; - register char *map; - register dump_ino_t ino; + struct dinode *dp; + int isdir; + char *map; + dump_ino_t ino; #ifndef __linux__ - register int i; + int i; long filesize; #else struct mapdirs_context mdc; @@ -606,7 +606,7 @@ static int dirindir(dump_ino_t ino, daddr_t blkno, int ind_level, long *filesize) { int ret = 0; - register int i; + int i; daddr_t idblk[MAXNINDIR]; bread(fsbtodb(sblock, blkno), (char *)idblk, (int)sblock->fs_bsize); @@ -691,8 +691,8 @@ searchdir(struct ext2_dir_entry *dp, int offset, int blocksize, char *buf, void static int searchdir(dump_ino_t ino, daddr_t blkno, long size, long filesize) { - register struct direct *dp; - register long loc, ret = 0; + struct direct *dp; + long loc, ret = 0; char dblk[MAXBSIZE]; bread(fsbtodb(sblock, blkno), dblk, (int)size); @@ -1130,7 +1130,7 @@ dmpindir(dump_ino_t ino, daddr_t blk, int ind_level, fsizeT *size) void blksout(daddr_t *blkp, int frags, dump_ino_t ino) { - register daddr_t *bp; + daddr_t *bp; int i, j, count, blks, tbperdb; blks = howmany(frags * sblock->fs_fsize, TP_BSIZE); @@ -1166,7 +1166,7 @@ blksout(daddr_t *blkp, int frags, dump_ino_t ino) void dumpmap(char *map, int type, dump_ino_t ino) { - register int i; + int i; char *cp; spcl.c_type = type; diff --git a/dump/unctime.c b/dump/unctime.c index 09bd48b..7f20c34 100644 --- a/dump/unctime.c +++ b/dump/unctime.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: unctime.c,v 1.13 2002/01/16 09:32:14 stelian Exp $"; + "$Id: unctime.c,v 1.14 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -114,7 +114,7 @@ static char months[] = static int lookup(const char *str) { - register const char *cp, *cp2; + const char *cp, *cp2; for (cp = months, cp2 = str; *cp != '\0'; cp += 3) if (strncmp(cp, cp2, 3) == 0) diff --git a/restore/dirs.c b/restore/dirs.c index 1910547..60f5b23 100644 --- a/restore/dirs.c +++ b/restore/dirs.c @@ -46,7 +46,7 @@ #ifndef lint static const char rcsid[] = - "$Id: dirs.c,v 1.16 2002/01/16 09:32:14 stelian Exp $"; + "$Id: dirs.c,v 1.17 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -164,11 +164,11 @@ static struct direct *searchdir __P((dump_ino_t, char *)); void extractdirs(int genmode) { - register int i; + int i; #ifdef __linux__ - register struct new_bsd_inode *ip; + struct new_bsd_inode *ip; #else - register struct dinode *ip; + struct dinode *ip; #endif struct inotab *itp; struct direct nulldir; @@ -252,8 +252,8 @@ skipdirs(void) void treescan(char *pname, dump_ino_t ino, long (*todo) __P((char *, dump_ino_t, int))) { - register struct inotab *itp; - register struct direct *dp; + struct inotab *itp; + struct direct *dp; int namelen; long bpt; char locname[MAXPATHLEN + 1]; @@ -340,8 +340,8 @@ pathsearch(const char *pathname) static struct direct * searchdir(dump_ino_t inum, char *name) { - register struct direct *dp; - register struct inotab *itp; + struct direct *dp; + struct inotab *itp; int len; itp = inotablookup(inum); @@ -364,9 +364,9 @@ static void putdir(char *buf, size_t size) { struct direct cvtbuf; - register struct odirect *odp; + struct odirect *odp; struct odirect *eodp; - register struct direct *dp; + struct direct *dp; long loc, i; if (cvtflag) { @@ -509,7 +509,7 @@ rst_seekdir(RST_DIR *dirp, long loc, long base) struct direct * rst_readdir(RST_DIR *dirp) { - register struct direct *dp; + struct direct *dp; for (;;) { if (dirp->dd_loc == 0) { @@ -590,8 +590,8 @@ rst_telldir(RST_DIR *dirp) static RST_DIR * opendirfile(const char *name) { - register RST_DIR *dirp; - register int fd; + RST_DIR *dirp; + int fd; if ((fd = open(name, O_RDONLY)) == -1) return (NULL); @@ -674,7 +674,7 @@ setdirmodes(int flags) int genliteraldir(char *name, dump_ino_t ino) { - register struct inotab *itp; + struct inotab *itp; int ofile, dp, i, size; char buf[BUFSIZ]; @@ -730,7 +730,7 @@ allocinotab(dump_ino_t ino, struct new_bsd_inode *dip, long seekpt) allocinotab(dump_ino_t ino, struct dinode *dip, long seekpt) #endif { - register struct inotab *itp; + struct inotab *itp; struct modeinfo node; itp = calloc(1, sizeof(struct inotab)); @@ -769,7 +769,7 @@ allocinotab(dump_ino_t ino, struct dinode *dip, long seekpt) static struct inotab * inotablookup(dump_ino_t ino) { - register struct inotab *itp; + struct inotab *itp; for (itp = inotab[INOHASH(ino)]; itp != NULL; itp = itp->t_next) if (itp->t_ino == ino) diff --git a/restore/interactive.c b/restore/interactive.c index fb29a4f..bc94ed4 100644 --- a/restore/interactive.c +++ b/restore/interactive.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: interactive.c,v 1.20 2002/01/25 14:59:53 stelian Exp $"; + "$Id: interactive.c,v 1.21 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -129,7 +129,7 @@ static void printlist __P((char *, char *)); void runcmdshell(void) { - register struct entry *np; + struct entry *np; dump_ino_t ino; struct arglist arglist; char curdir[MAXPATHLEN]; @@ -357,7 +357,7 @@ loop: static void getcmd(char *curdir, char *cmd, char *name, int size, struct arglist *ap) { - register char *cp; + char *cp; static char input[BUFSIZ]; char output[BUFSIZ]; # define rawname input /* save space by reusing input buffer */ @@ -453,7 +453,7 @@ retnext: static char * copynext(char *input, char *output) { - register char *cp, *bp; + char *cp, *bp; char quote; for (cp = input; *cp == ' ' || *cp == '\t'; cp++) @@ -502,7 +502,7 @@ copynext(char *input, char *output) void canon(char *rawname, char *canonname, int len) { - register char *cp, *np; + char *cp, *np; if (strcmp(rawname, ".") == 0 || strncmp(rawname, "./", 2) == 0) (void) strcpy(canonname, ""); @@ -554,8 +554,8 @@ canon(char *rawname, char *canonname, int len) static void printlist(char *name, char *basename) { - register struct afile *fp, *list, *listp = NULL; - register struct direct *dp; + struct afile *fp, *list, *listp = NULL; + struct direct *dp; struct afile single; RST_DIR *dirp; int entries, len, namelen; @@ -699,7 +699,7 @@ mkentry(char *name, struct direct *dp, struct afile *fp) static void formatf(struct afile *list, int nentry) { - register struct afile *fp, *endlist; + struct afile *fp, *endlist; int width, bigino, haveprefix, havepostfix; int i, j, w, precision = 0, columns, lines; @@ -796,7 +796,7 @@ glob_readdir(RST_DIR *dirp) static int glob_stat(const char *name, struct stat *stp) { - register struct direct *dp; + struct direct *dp; dp = pathsearch(name); if (dp == NULL || (!dflag && TSTINO(dp->d_ino, dumpmap) == 0) || (!vflag && dp->d_ino == WINO)) diff --git a/restore/restore.c b/restore/restore.c index a44f50d..1b04fea 100644 --- a/restore/restore.c +++ b/restore/restore.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: restore.c,v 1.25 2002/01/25 14:59:53 stelian Exp $"; + "$Id: restore.c,v 1.26 2002/01/25 15:08:59 stelian Exp $"; #endif /* not lint */ #include @@ -108,7 +108,7 @@ listfile(char *name, dump_ino_t ino, int type) long addfile(char *name, dump_ino_t ino, int type) { - register struct entry *ep, *np; + struct entry *ep, *np; long descend = hflag ? GOOD : FAIL; char buf[100]; @@ -192,8 +192,8 @@ static struct entry *removelist; void removeoldleaves(void) { - register struct entry *ep, *nextep; - register dump_ino_t i, mydirino; + struct entry *ep, *nextep; + dump_ino_t i, mydirino; Vprintf(stdout, "Mark entries to be removed.\n"); if ((ep = lookupino(WINO))) { @@ -249,7 +249,7 @@ removeoldleaves(void) long nodeupdates(char *name, dump_ino_t ino, int type) { - register struct entry *ep, *np, *ip; + struct entry *ep, *np, *ip; long descend = GOOD; int lookuptype = 0; int key = 0; @@ -558,8 +558,8 @@ keyval(int key) void findunreflinks(void) { - register struct entry *ep, *np; - register dump_ino_t i; + struct entry *ep, *np; + dump_ino_t i; Vprintf(stdout, "Find unreferenced names.\n"); for (i = ROOTINO; i < maxino; i++) { @@ -606,7 +606,7 @@ findunreflinks(void) void removeoldnodes(void) { - register struct entry *ep, **prev; + struct entry *ep, **prev; long change; Vprintf(stdout, "Remove old nodes (directories).\n"); @@ -649,7 +649,7 @@ compare_entry(struct entry *ep, int do_compare) void compareleaves(void) { - register struct entry *ep; + struct entry *ep; dump_ino_t first; long curvol; @@ -736,7 +736,7 @@ compareleaves(void) void createleaves(char *symtabfile) { - register struct entry *ep; + struct entry *ep; dump_ino_t first; long curvol; @@ -835,8 +835,8 @@ createleaves(char *symtabfile) void createfiles(void) { - register dump_ino_t first, next, last; - register struct entry *ep; + dump_ino_t first, next, last; + struct entry *ep; long curvol; #ifdef USE_QFA long tnum, tmpcnt; @@ -1016,8 +1016,8 @@ createfiles(void) void createlinks(void) { - register struct entry *np, *ep; - register dump_ino_t i; + struct entry *np, *ep; + dump_ino_t i; char name[BUFSIZ]; if ((ep = lookupino(WINO))) { @@ -1060,8 +1060,8 @@ createlinks(void) void checkrestore(void) { - register struct entry *ep; - register dump_ino_t i; + struct entry *ep; + dump_ino_t i; Vprintf(stdout, "Check the symbol table.\n"); for (i = WINO; i < maxino; i++) { diff --git a/restore/symtab.c b/restore/symtab.c index 9eb9dc0..99312ac 100644 --- a/restore/symtab.c +++ b/restore/symtab.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: symtab.c,v 1.17 2002/01/16 09:32:14 stelian Exp $"; + "$Id: symtab.c,v 1.18 2002/01/25 15:09:00 stelian Exp $"; #endif /* not lint */ /* @@ -106,7 +106,7 @@ static void removeentry __P((struct entry *)); struct entry * lookupino(dump_ino_t inum) { - register struct entry *ep; + struct entry *ep; if (inum < WINO || inum >= maxino) return (NULL); @@ -142,7 +142,7 @@ addino(dump_ino_t inum, struct entry *np) void deleteino(dump_ino_t inum) { - register struct entry *next; + struct entry *next; struct entry **prev; if (inum < WINO || inum >= maxino) @@ -165,8 +165,8 @@ deleteino(dump_ino_t inum) struct entry * lookupname(char *name) { - register struct entry *ep; - register char *np, *cp; + struct entry *ep; + char *np, *cp; char buf[MAXPATHLEN]; cp = name; @@ -216,7 +216,7 @@ lookupparent(char *name) char * myname(struct entry *ep) { - register char *cp; + char *cp; static char namebuf[MAXPATHLEN]; for (cp = &namebuf[MAXPATHLEN - 2]; cp > &namebuf[ep->e_namlen]; ) { @@ -243,7 +243,7 @@ static struct entry *freelist = NULL; struct entry * addentry(char *name, dump_ino_t inum, int type) { - register struct entry *np, *ep; + struct entry *np, *ep; if (freelist != NULL) { np = freelist; @@ -291,7 +291,7 @@ addentry(char *name, dump_ino_t inum, int type) void freeentry(struct entry *ep) { - register struct entry *np; + struct entry *np; dump_ino_t inum; if (ep->e_flags != REMOVED) @@ -362,7 +362,7 @@ moveentry(struct entry *ep, char *newname) static void removeentry(struct entry *ep) { - register struct entry *np; + struct entry *np; np = ep->e_parent; if (np->e_entries == ep) { @@ -462,8 +462,8 @@ struct symtableheader { void dumpsymtable(char *filename, long checkpt) { - register struct entry *ep, *tep; - register dump_ino_t i; + struct entry *ep, *tep; + dump_ino_t i; struct entry temp, *tentry; long mynum = 1, stroff = 0; FILE *fd; @@ -550,11 +550,11 @@ initsymtable(char *filename) { char *base; long tblsize; - register struct entry *ep; + struct entry *ep; struct entry *baseep, *lep; struct symtableheader hdr; struct stat stbuf; - register long i; + long i; int fd; Vprintf(stdout, "Initialize symbol table.\n"); diff --git a/restore/tape.c b/restore/tape.c index ff524ce..3c9085b 100644 --- a/restore/tape.c +++ b/restore/tape.c @@ -46,7 +46,7 @@ #ifndef lint static const char rcsid[] = - "$Id: tape.c,v 1.55 2002/01/25 14:59:53 stelian Exp $"; + "$Id: tape.c,v 1.56 2002/01/25 15:09:00 stelian Exp $"; #endif /* not lint */ #include @@ -853,7 +853,7 @@ skipfile(void) void getfile(void (*fill) __P((char *, size_t)), void (*skip) __P((char *, size_t))) { - register int i; + int i; volatile int curblk = 0; volatile quad_t size = spcl.c_dinode.di_size; volatile int last_write_was_hole = 0; @@ -2265,7 +2265,7 @@ findinode(struct s_spcl *header) static int checksum(int *buf) { - register int i, j; + int i, j; j = sizeof(union u_spcl) / sizeof(int); i = 0; diff --git a/restore/utilities.c b/restore/utilities.c index 4960b9a..627e147 100644 --- a/restore/utilities.c +++ b/restore/utilities.c @@ -41,7 +41,7 @@ #ifndef lint static const char rcsid[] = - "$Id: utilities.c,v 1.18 2002/01/25 14:59:53 stelian Exp $"; + "$Id: utilities.c,v 1.19 2002/01/25 15:09:00 stelian Exp $"; #endif /* not lint */ #include @@ -78,7 +78,7 @@ static const char rcsid[] = void pathcheck(char *name) { - register char *cp; + char *cp; struct entry *ep; char *start; @@ -319,7 +319,7 @@ delwhiteout(struct entry *ep) dump_ino_t lowerbnd(dump_ino_t start) { - register struct entry *ep; + struct entry *ep; for ( ; start < maxino; start++) { ep = lookupino(start); @@ -337,7 +337,7 @@ lowerbnd(dump_ino_t start) dump_ino_t upperbnd(dump_ino_t start) { - register struct entry *ep; + struct entry *ep; for ( ; start > ROOTINO; start--) { ep = lookupino(start); -- 2.39.5