summaryrefslogtreecommitdiff
path: root/grep.c
diff options
context:
space:
mode:
Diffstat (limited to 'grep.c')
-rw-r--r--grep.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/grep.c b/grep.c
index 4e155ee9e6..932647e4a6 100644
--- a/grep.c
+++ b/grep.c
@@ -5,7 +5,7 @@
#include "gettext.h"
#include "grep.h"
#include "hex.h"
-#include "object-store-ll.h"
+#include "odb.h"
#include "pretty.h"
#include "userdiff.h"
#include "xdiff-interface.h"
@@ -1517,7 +1517,7 @@ static int fill_textconv_grep(struct repository *r,
fill_filespec(df, gs->identifier, 1, 0100644);
break;
case GREP_SOURCE_FILE:
- fill_filespec(df, null_oid(), 0, 0100644);
+ fill_filespec(df, null_oid(r->hash_algo), 0, 0100644);
break;
default:
BUG("attempt to textconv something without a path?");
@@ -1931,8 +1931,8 @@ static int grep_source_load_oid(struct grep_source *gs)
{
enum object_type type;
- gs->buf = repo_read_object_file(gs->repo, gs->identifier, &type,
- &gs->size);
+ gs->buf = odb_read_object(gs->repo->objects, gs->identifier,
+ &type, &gs->size);
if (!gs->buf)
return error(_("'%s': unable to read %s"),
gs->name,