From 2de381f919829aec1e35d6c7cc33519295dcd053 Mon Sep 17 00:00:00 2001 From: Petr Baudis Date: Wed, 13 Apr 2005 02:28:48 -0700 Subject: [PATCH] Consolidate the error handling Now there is error() for "library" errors and die() for fatal "application" errors. usage() is now used strictly only for usage errors. Signed-off-by: Petr Baudis --- fsck-cache.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'fsck-cache.c') diff --git a/fsck-cache.c b/fsck-cache.c index bb5cf196af..2bb3a64a3b 100644 --- a/fsck-cache.c +++ b/fsck-cache.c @@ -205,8 +205,7 @@ static int fsck_dir(int i, char *path) struct dirent *de; if (!dir) { - fprintf(stderr, "missing sha1 directory '%s'", path); - return -1; + return error("missing sha1 directory '%s'", path); } while ((de = readdir(dir)) != NULL) { -- cgit v1.2.3