]> git.wh0rd.org - dump.git/blobdiff - compat/lib/fstab.c
Version 0.4b6.
[dump.git] / compat / lib / fstab.c
index 0cd2250c4023bb0090f421f05bdf59846be5f04b..cc2d2550dd33eb7c2f007bdac2aa6195936d2768 100644 (file)
@@ -1,7 +1,8 @@
 /*
  *     Ported to Linux's Second Extended File System as part of the
  *     dump and restore backup suit
- *     Remy Card <card@Linux.EU.Org>, 1994, 1995, 1996
+ *     Remy Card <card@Linux.EU.Org>, 1994-1997
+ *      Stelian Pop <pop@cybercable.fr>, 1999
  *
  */
 
@@ -57,7 +58,7 @@ static void error __P((int));
 static int fstabscan __P((void));
 
 static
-int fstabscan()
+int fstabscan(void)
 {
        struct mntent   *mnt;
        register char *cp;
@@ -110,16 +111,15 @@ int fstabscan()
 }
 
 struct fstab *
-getfsent()
+getfsent(void)
 {
-       if (!_fs_fp && !setfsent() || !fstabscan())
+       if ((!_fs_fp && !setfsent()) || !fstabscan())
                return((struct fstab *)NULL);
        return(&_fs_fstab);
 }
 
 struct fstab *
-getfsspec(name)
-       register const char *name;
+getfsspec(const char *name)
 {
        if (setfsent())
                while (fstabscan())
@@ -129,8 +129,7 @@ getfsspec(name)
 }
 
 struct fstab *
-getfsfile(name)
-       register const char *name;
+getfsfile(const char *name)
 {
        if (setfsent())
                while (fstabscan())
@@ -139,7 +138,8 @@ getfsfile(name)
        return((struct fstab *)NULL);
 }
 
-int setfsent()
+int
+setfsent(void)
 {
        if (_fs_fp) {
                rewind(_fs_fp);
@@ -152,7 +152,7 @@ int setfsent()
 }
 
 void
-endfsent()
+endfsent(void)
 {
        if (_fs_fp) {
                (void)endmntent(_fs_fp);
@@ -161,8 +161,7 @@ endfsent()
 }
 
 static
-void error(err)
-       int err;
+void error(int err)
 {
        char *p;