Merge branch 'pb/strbuf-read-file-doc'
[gitweb.git] / tree.c
diff --git a/tree.c b/tree.c
index f79ff9813e37529cf7adbcda307027b0495cfb1c..0089e52d9dff41bece11056e92625b923515c462 100644 (file)
--- a/tree.c
+++ b/tree.c
@@ -76,7 +76,7 @@ static int read_tree_1(struct tree *tree, struct strbuf *base,
                                continue;
                }
 
-               switch (fn(entry.sha1, base,
+               switch (fn(entry.oid->hash, base,
                           entry.path, entry.mode, stage, context)) {
                case 0:
                        continue;
@@ -87,19 +87,19 @@ static int read_tree_1(struct tree *tree, struct strbuf *base,
                }
 
                if (S_ISDIR(entry.mode))
-                       hashcpy(sha1, entry.sha1);
+                       hashcpy(sha1, entry.oid->hash);
                else if (S_ISGITLINK(entry.mode)) {
                        struct commit *commit;
 
-                       commit = lookup_commit(entry.sha1);
+                       commit = lookup_commit(entry.oid->hash);
                        if (!commit)
                                die("Commit %s in submodule path %s%s not found",
-                                   sha1_to_hex(entry.sha1),
+                                   oid_to_hex(entry.oid),
                                    base->buf, entry.path);
 
                        if (parse_commit(commit))
                                die("Invalid commit %s in submodule path %s%s",
-                                   sha1_to_hex(entry.sha1),
+                                   oid_to_hex(entry.oid),
                                    base->buf, entry.path);
 
                        hashcpy(sha1, commit->tree->object.oid.hash);