Merge branch 'jk/info-alternates-fix'
We used to add an empty alternate object database to the system that does not help anything; it has been corrected. * jk/info-alternates-fix: link_alt_odb_entries: make empty input a noopmaint
commit
26a45eac80
|
@ -404,6 +404,9 @@ static void link_alt_odb_entries(const char *alt, int sep,
|
||||||
struct strbuf objdirbuf = STRBUF_INIT;
|
struct strbuf objdirbuf = STRBUF_INIT;
|
||||||
struct strbuf entry = STRBUF_INIT;
|
struct strbuf entry = STRBUF_INIT;
|
||||||
|
|
||||||
|
if (!alt || !*alt)
|
||||||
|
return;
|
||||||
|
|
||||||
if (depth > 5) {
|
if (depth > 5) {
|
||||||
error("%s: ignoring alternate object stores, nesting too deep.",
|
error("%s: ignoring alternate object stores, nesting too deep.",
|
||||||
relative_base);
|
relative_base);
|
||||||
|
@ -604,7 +607,6 @@ void prepare_alt_odb(void)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
alt = getenv(ALTERNATE_DB_ENVIRONMENT);
|
alt = getenv(ALTERNATE_DB_ENVIRONMENT);
|
||||||
if (!alt) alt = "";
|
|
||||||
|
|
||||||
alt_odb_tail = &alt_odb_list;
|
alt_odb_tail = &alt_odb_list;
|
||||||
link_alt_odb_entries(alt, PATH_SEP, NULL, 0);
|
link_alt_odb_entries(alt, PATH_SEP, NULL, 0);
|
||||||
|
|
Loading…
Reference in New Issue