Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src/odb.c
diff options
context:
space:
mode:
authorVicent Marti <tanoku@gmail.com>2013-05-04 01:30:54 +0400
committerVicent Marti <tanoku@gmail.com>2013-05-04 01:30:54 +0400
commitdfec726bbae0e699b78db8f1b63372134c8467a6 (patch)
tree56aff583eed5574ed13fc3c83d86affc3fef92fd /src/odb.c
parentb641c00eebb3c60e8719c0dfc55dde91ca30a5d2 (diff)
odb: Do not error out if an alternate ODB is missing
Diffstat (limited to 'src/odb.c')
-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;
}