|
23 | 23 |
|
24 | 24 | #define GIT_ALTERNATES_FILE "info/alternates" |
25 | 25 |
|
| 26 | +#define GIT_ALTERNATES_MAX_DEPTH 5 |
| 27 | + |
26 | 28 | /* |
27 | 29 | * We work under the assumption that most objects for long-running |
28 | 30 | * operations will be packed |
29 | 31 | */ |
30 | | -#define GIT_LOOSE_PRIORITY 1 |
31 | | -#define GIT_PACKED_PRIORITY 2 |
32 | | - |
33 | | -#define GIT_ALTERNATES_MAX_DEPTH 5 |
| 32 | +int git_odb__loose_priority = 1; |
| 33 | +int git_odb__packed_priority = 2; |
34 | 34 |
|
35 | 35 | bool git_odb__strict_hash_verification = true; |
36 | 36 |
|
@@ -613,12 +613,12 @@ int git_odb__add_default_backends( |
613 | 613 |
|
614 | 614 | /* add the loose object backend */ |
615 | 615 | if (git_odb_backend_loose(&loose, objects_dir, -1, db->do_fsync, 0, 0) < 0 || |
616 | | - add_backend_internal(db, loose, GIT_LOOSE_PRIORITY, as_alternates, inode) < 0) |
| 616 | + add_backend_internal(db, loose, git_odb__loose_priority, as_alternates, inode) < 0) |
617 | 617 | return -1; |
618 | 618 |
|
619 | 619 | /* add the packed file backend */ |
620 | 620 | if (git_odb_backend_pack(&packed, objects_dir) < 0 || |
621 | | - add_backend_internal(db, packed, GIT_PACKED_PRIORITY, as_alternates, inode) < 0) |
| 621 | + add_backend_internal(db, packed, git_odb__packed_priority, as_alternates, inode) < 0) |
622 | 622 | return -1; |
623 | 623 |
|
624 | 624 | if (git_mutex_lock(&db->lock) < 0) { |
|
0 commit comments