X-Git-Url: https://git.wh0rd.org/?p=dump.git;a=blobdiff_plain;f=restore%2Ftape.c;h=145f769b949308e38e343a60bd7bbaf4f2e7c098;hp=2bb447239bed286d20afbe0de2cb57f2afdf7215;hb=1176b3c1cb187c6c9f223c154fb4d58910717d18;hpb=d3e542e79b851bab1b4cc7482694d413c42c6e63 diff --git a/restore/tape.c b/restore/tape.c index 2bb4472..145f769 100644 --- a/restore/tape.c +++ b/restore/tape.c @@ -46,7 +46,7 @@ #ifndef lint static const char rcsid[] = - "$Id: tape.c,v 1.67 2003/01/10 14:42:51 stelian Exp $"; + "$Id: tape.c,v 1.68 2003/02/11 09:56:48 stelian Exp $"; #endif /* not lint */ #include @@ -1266,6 +1266,16 @@ comparefile(char *name) struct STAT stemp; #endif + curfile.name = name; + curfile.action = USING; + mode = curfile.dip->di_mode; + + if ((mode & IFMT) == IFSOCK) { + Vprintf(stdout, "skipped socket %s\n", name); + skipfile(); + return; + } + if ((r = LSTAT(name, &sb)) != 0) { warn("%s: does not exist (%d)", name, r); do_compare_error; @@ -1273,10 +1283,6 @@ comparefile(char *name) return; } - curfile.name = name; - curfile.action = USING; - mode = curfile.dip->di_mode; - Vprintf(stdout, "comparing %s (size: %ld, mode: 0%o)\n", name, (long)sb.st_size, mode);