add symbolic links
authorKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Tue, 23 Mar 1982 17:03:39 +0000 (09:03 -0800)
committerKirk McKusick <mckusick@ucbvax.Berkeley.EDU>
Tue, 23 Mar 1982 17:03:39 +0000 (09:03 -0800)
SCCS-vsn: sbin/fsck/main.c 1.27
SCCS-vsn: sbin/icheck/icheck.c 1.20

usr/src/sbin/fsck/main.c
usr/src/sbin/icheck/icheck.c

index 575f736..380dd9c 100644 (file)
@@ -1,4 +1,4 @@
-static char *sccsid = "@(#)main.c      1.26 (Berkeley) %G%";
+static char *sccsid = "@(#)main.c      1.27 (Berkeley) %G%";
 
 #include <stdio.h>
 #include <ctype.h>
 
 #include <stdio.h>
 #include <ctype.h>
@@ -32,9 +32,7 @@ typedef struct direct DIRECT;
 #define        REG     ((dp->di_mode & IFMT) == IFREG)
 #define        BLK     ((dp->di_mode & IFMT) == IFBLK)
 #define        CHR     ((dp->di_mode & IFMT) == IFCHR)
 #define        REG     ((dp->di_mode & IFMT) == IFREG)
 #define        BLK     ((dp->di_mode & IFMT) == IFBLK)
 #define        CHR     ((dp->di_mode & IFMT) == IFCHR)
-#define        MPC     ((dp->di_mode & IFMT) == IFMPC)
-#define        MPB     ((dp->di_mode & IFMT) == IFMPB)
-#define        SPECIAL (BLK || CHR || MPC || MPB)
+#define        SPECIAL (BLK || CHR)
 
 ino_t  startinum;              /* blk num of first in raw area */
 
 
 ino_t  startinum;              /* blk num of first in raw area */
 
@@ -1349,8 +1347,7 @@ ftypeok(dp)
        case IFREG:
        case IFBLK:
        case IFCHR:
        case IFREG:
        case IFBLK:
        case IFCHR:
-       case IFMPC:
-       case IFMPB:
+       case IFLNK:
                return (1);
 
        default:
                return (1);
 
        default:
index 212e088..1e36e98 100644 (file)
@@ -1,4 +1,4 @@
-static char *sccsid = "@(#)icheck.c    1.19 (Berkeley) %G%";
+static char *sccsid = "@(#)icheck.c    1.20 (Berkeley) %G%";
 
 /*
  * icheck
 
 /*
  * icheck
@@ -41,7 +41,7 @@ ino_t nrfile;
 ino_t  ndfile;
 ino_t  nbfile;
 ino_t  ncfile;
 ino_t  ndfile;
 ino_t  nbfile;
 ino_t  ncfile;
-ino_t  nmcfile;
+ino_t  nlfile;
 
 daddr_t        nblock;
 daddr_t        nfrag;
 
 daddr_t        nblock;
 daddr_t        nfrag;
@@ -136,7 +136,7 @@ check(file)
        ndfile = 0;
        ncfile = 0;
        nbfile = 0;
        ndfile = 0;
        ncfile = 0;
        nbfile = 0;
-       nmcfile = 0;
+       nlfile = 0;
 
        nblock = 0;
        nfrag = 0;
 
        nblock = 0;
        nfrag = 0;
@@ -238,13 +238,13 @@ check(file)
                free(bmap);
 #endif
 
                free(bmap);
 #endif
 
-       i = nrfile + ndfile + ncfile + nbfile + nmcfile;
+       i = nrfile + ndfile + ncfile + nbfile + nlfile;
 #ifndef STANDALONE
 #ifndef STANDALONE
-       printf("files %6u (r=%u,d=%u,b=%u,c=%u,mc=%u)\n",
-               i, nrfile, ndfile, nbfile, ncfile, nmcfile);
+       printf("files %6u (r=%u,d=%u,b=%u,c=%u,sl=%u)\n",
+               i, nrfile, ndfile, nbfile, ncfile, nlfile);
 #else
 #else
-       printf("files %u (r=%u,d=%u,b=%u,c=%u,mc=%u)\n",
-               i, nrfile, ndfile, nbfile, ncfile, nmcfile);
+       printf("files %u (r=%u,d=%u,b=%u,c=%u,sl=%u)\n",
+               i, nrfile, ndfile, nbfile, ncfile, nlfile);
 #endif
        n = (nblock + nindir + niindir) * sblock.fs_frag + nfrag;
 #ifdef STANDALONE
 #endif
        n = (nblock + nindir + niindir) * sblock.fs_frag + nfrag;
 #ifdef STANDALONE
@@ -294,6 +294,9 @@ pass1(ip)
        case IFREG:
                nrfile++;
                break;
        case IFREG:
                nrfile++;
                break;
+       case IFLNK:
+               nlfile++;
+               break;
        default:
                printf("bad mode %u\n", ino);
                return;
        default:
                printf("bad mode %u\n", ino);
                return;