]> git.wh0rd.org - dump.git/blobdiff - restore/tape.c
Fix invalid EA metainformation in dump, add a workaround to restore to
[dump.git] / restore / tape.c
index 02892464bdd4d73572e119cfb7ece65a359615a3..3dc8bbaf7feb89560c699b8bb7d95b9f4439fa45 100644 (file)
@@ -42,7 +42,7 @@
 
 #ifndef lint
 static const char rcsid[] =
-       "$Id: tape.c,v 1.95 2009/12/04 16:29:18 stelian Exp $";
+       "$Id: tape.c,v 1.96 2010/03/22 15:40:55 stelian Exp $";
 #endif /* not lint */
 
 #include <config.h>
@@ -1238,12 +1238,20 @@ readxattr(char *buffer)
                skipfile();
                return (FAIL);
        }
-       
+
        memset(xattrbuf, 0, XATTR_MAXSIZE);
        xattrlen = 0;
 
+       /*
+        * ugly hack: cope with invalid spcl.c_addr[] records written by
+        * old versions of dump.
+        */
+       readmapflag = 1;
+
        getfile(xtrxattr, xtrnull);
 
+       readmapflag = 0;
+
        memcpy(buffer, xattrbuf, XATTR_MAXSIZE);
 
        return (GOOD);