]> git.wh0rd.org - dump.git/blobdiff - restore/tape.c
Small libc5 compile glitches.
[dump.git] / restore / tape.c
index ab0513a919573bf06e0e31b63059c8bc4b098791..ba772a72fff19d0ea652052c04231ec43170c2c3 100644 (file)
@@ -2,8 +2,7 @@
  *     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 
- *
+ *     Stelian Pop <pop@cybercable.fr>, 1999 
  */
 
 /*
  */
 
 #ifndef lint
-#if 0
-static char sccsid[] = "@(#)tape.c     8.9 (Berkeley) 5/1/95";
-#endif
 static const char rcsid[] =
-       "$Id: tape.c,v 1.4 1999/10/11 13:08:10 stelian Exp $";
+       "$Id: tape.c,v 1.8 1999/11/11 16:14:01 tiniou Exp $";
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -570,9 +566,11 @@ extractfile(char *name)
                return (genliteraldir(name, curfile.ino));
 
        case IFLNK:
-       {       uid_t luid = curfile.dip->di_uid;
+       {
+#ifdef HAVE_LCHOWN
+               uid_t luid = curfile.dip->di_uid;
                gid_t lgid = curfile.dip->di_gid;
-
+#endif
                lnkbuf[0] = '\0';
                pathlen = 0;
                getfile(xtrlnkfile, xtrlnkskip);
@@ -583,7 +581,9 @@ extractfile(char *name)
                }
                if (linkit(lnkbuf, name, SYMLINK) == FAIL)
                        return (FAIL);
-               (void) chown(name, luid, lgid);
+#ifdef HAVE_LCHOWN
+               (void) lchown(name, luid, lgid);
+#endif
                return (GOOD);
        }