sha1_file: add raw_object_store argument to alt_odb_usable
[gitweb.git] / builtin / pack-redundant.c
index cb1df1c7614b4a91f2ed39ffe1f31dfdbcbe793e..b5b007e706ad4ac2b84d13c1c76222a04c1e65e5 100644 (file)
@@ -7,6 +7,9 @@
 */
 
 #include "builtin.h"
+#include "repository.h"
+#include "packfile.h"
+#include "object-store.h"
 
 #define BLKSIZE 512
 
@@ -570,7 +573,7 @@ static struct pack_list * add_pack(struct packed_git *p)
 
 static struct pack_list * add_pack_file(const char *filename)
 {
-       struct packed_git *p = packed_git;
+       struct packed_git *p = get_packed_git(the_repository);
 
        if (strlen(filename) < 40)
                die("Bad pack filename: %s", filename);
@@ -585,7 +588,7 @@ static struct pack_list * add_pack_file(const char *filename)
 
 static void load_all(void)
 {
-       struct packed_git *p = packed_git;
+       struct packed_git *p = get_packed_git(the_repository);
 
        while (p) {
                add_pack(p);