mirror of
https://github.com/openbsd/src.git
synced 2025-01-10 06:47:55 -08:00
Correct exit codes for extra files. PR 5072.
Reminded by millert. ok millert, deraaadt
This commit is contained in:
parent
57ff11c7a8
commit
3126895ea6
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: mtree.h,v 1.11 2005/08/10 00:42:09 millert Exp $ */
|
||||
/* $OpenBSD: mtree.h,v 1.12 2008/10/08 12:17:02 kili Exp $ */
|
||||
/* $NetBSD: mtree.h,v 1.7 1995/03/07 21:26:27 cgd Exp $ */
|
||||
|
||||
/*-
|
||||
@ -41,6 +41,7 @@
|
||||
#define KEYDEFAULT \
|
||||
(F_GID | F_MODE | F_NLINK | F_SIZE | F_SLINK | F_TIME | F_UID)
|
||||
|
||||
#define ERROREXIT 1
|
||||
#define MISMATCHEXIT 2
|
||||
|
||||
typedef struct _node {
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: verify.c,v 1.16 2004/11/21 19:36:04 otto Exp $ */
|
||||
/* $OpenBSD: verify.c,v 1.17 2008/10/08 12:17:02 kili Exp $ */
|
||||
/* $NetBSD: verify.c,v 1.10 1995/03/07 21:26:28 cgd Exp $ */
|
||||
|
||||
/*-
|
||||
@ -34,7 +34,7 @@
|
||||
#if 0
|
||||
static const char sccsid[] = "@(#)verify.c 8.1 (Berkeley) 6/6/93";
|
||||
#else
|
||||
static const char rcsid[] = "$OpenBSD: verify.c,v 1.16 2004/11/21 19:36:04 otto Exp $";
|
||||
static const char rcsid[] = "$OpenBSD: verify.c,v 1.17 2008/10/08 12:17:02 kili Exp $";
|
||||
#endif
|
||||
#endif /* not lint */
|
||||
|
||||
@ -138,9 +138,11 @@ extra:
|
||||
? rmdir : unlink)(p->fts_accpath)) {
|
||||
(void)printf(", not removed: %s",
|
||||
strerror(errno));
|
||||
rval = ERROREXIT;
|
||||
} else
|
||||
(void)printf(", removed");
|
||||
}
|
||||
} else
|
||||
rval = MISMATCHEXIT;
|
||||
(void)putchar('\n');
|
||||
}
|
||||
(void)fts_set(t, p, FTS_SKIP);
|
||||
|
Loading…
Reference in New Issue
Block a user