summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/odb.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/odb.c b/src/odb.c
index 07e1ea6eb..7b5e555a2 100644
--- a/src/odb.c
+++ b/src/odb.c
@@ -457,6 +457,9 @@ static int add_default_backends(
inode = 0;
#else
if (p_stat(objects_dir, &st) < 0) {
+ if (as_alternates)
+ return 0;
+
giterr_set(GITERR_ODB, "Failed to load object database in '%s'", objects_dir);
return -1;
}