X-Git-Url: https://git.wh0rd.org/?a=blobdiff_plain;f=restore%2Fmain.c;h=b2d8c0538bf2c65307950dd39945ec20eb1d85c5;hb=d6967896bc4e18f9b4359a2ef5be5c0f1bcc456a;hp=1cd1a662981ec7b85210053568106c19048176eb;hpb=1a05d45daf5f6259b1aab68092daba0cad77f1ac;p=dump.git diff --git a/restore/main.c b/restore/main.c index 1cd1a66..b2d8c05 100644 --- a/restore/main.c +++ b/restore/main.c @@ -2,7 +2,8 @@ * Ported to Linux's Second Extended File System as part of the * dump and restore backup suit * Remy Card , 1994-1997 - * Stelian Pop , 1999-2000 + * Stelian Pop , 1999-2000 + * Stelian Pop - AlcĂ´ve , 2000 */ /* @@ -40,9 +41,10 @@ #ifndef lint static const char rcsid[] = - "$Id: main.c,v 1.11 2000/03/09 13:12:31 stelian Exp $"; + "$Id: main.c,v 1.15 2000/12/21 11:14:54 stelian Exp $"; #endif /* not lint */ +#include #include #include #include @@ -87,6 +89,7 @@ time_t dumpdate; FILE *terminal; char *tmpdir; int compare_ignore_not_found; +int compare_errors; char filesys[NAMELEN]; static const char *stdin_opt = NULL; @@ -250,6 +253,7 @@ main(int argc, char *argv[]) Vprintf(stdout, "Begin compare restore\n"); compare_ignore_not_found = 0; + compare_errors = 0; setup(); printf("filesys = %s\n", filesys); if (stat(filesys, &stbuf) < 0) @@ -262,6 +266,10 @@ main(int argc, char *argv[]) treescan(".", ROOTINO, nodeupdates); compareleaves(); checkrestore(); + if (compare_errors) { + printf("Some files were modified!\n"); + exit(2); + } break; }