]> git.wh0rd.org - dump.git/blobdiff - dump/traverse.c
cybercable -> noos.
[dump.git] / dump / traverse.c
index 9182b4052677c137b6819a668a7b9e7821cbbf1b..a49434bdd50943ab9ee95353933132c4308fe9de 100644 (file)
@@ -2,7 +2,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-1997
- *     Stelian Pop <pop@cybercable.fr>, 1999-2000
+ *     Stelian Pop <pop@noos.fr>, 1999-2000
+ *     Stelian Pop <pop@noos.fr> - AlcĂ´ve <www.alcove.fr>, 2000
  */
 
 /*-
@@ -40,7 +41,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-       "$Id: traverse.c,v 1.20 2000/09/26 13:17:09 stelian Exp $";
+       "$Id: traverse.c,v 1.23 2000/12/04 15:43:16 stelian Exp $";
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -105,18 +106,19 @@ static    int searchdir __P((ino_t ino, daddr_t blkno, long size, long filesize));
 static void mapfileino __P((ino_t ino, long *tapesize, int *dirskipped));
 static int exclude_ino __P((ino_t ino));
 
-/* #define EXT3_FEATURE_INCOMPAT_RECOVER */
+/* #define EXT3_FEATURE_INCOMPAT_RECOVER       0x0004 */
+#ifdef EXT3_FEATURE_INCOMPAT_RECOVER
+#define FORCE_OPEN     EXT2_FLAG_FORCE
+#else
+#define FORCE_OPEN     0
+#endif
 
 int dump_fs_open(const char *disk, ext2_filsys *fs)
 {
        int retval;
        struct ext2fs_sb *s;
 
-#ifdef EXT3_FEATURE_INCOMPAT_RECOVER
-       retval = ext2fs_open(disk, EXT2_FLAG_FORCE, 0, 0, unix_io_manager, fs);
-#else
-       retval = ext2fs_open(disk, 0, 0, 0, unix_io_manager, fs);
-#endif
+       retval = ext2fs_open(disk, FORCE_OPEN, 0, 0, unix_io_manager, fs);
 #if defined(EXT2_LIB_FEATURE_COMPAT_SUPP) && defined(EXT2_LIB_FEATURE_INCOMPAT_SUPP) && defined(EXT2_LIB_FEATURE_RO_COMPAT_SUPP) && defined(EXT2_ET_UNSUPP_FEATURE) && defined(EXT2_ET_RO_UNSUPP_FEATURE)
        if (!retval) {
                s = (struct ext2fs_sb *) (*fs)->super;