summaryrefslogtreecommitdiff
path: root/fsck-cache.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-09 00:25:22 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-09 00:25:22 -0700
commit59c1e249808c6ba38194733fa00efddb9e0eb488 (patch)
tree8bd5667ce5588ab02c103c9aa8d8f1c6e90da56f /fsck-cache.c
parent1ea34e365b1ea233be332245bc34a8df415a7d61 (diff)
downloadgit-59c1e249808c6ba38194733fa00efddb9e0eb488.tar.gz
Fix missing return values and some error tests for empty index files
Patches from Dave Jones and Ingo Molnar, but since I don't have any infrastructure in place to use the old patch applicator scripts I am trying to build up, I ended up fixing the thing by hand instead. Credit where credit is due, though. Nice to see that people are taking a look at the project even in this early stage.
Diffstat (limited to 'fsck-cache.c')
-rw-r--r--fsck-cache.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fsck-cache.c b/fsck-cache.c
index 0a97566e87..a01513ed4d 100644
--- a/fsck-cache.c
+++ b/fsck-cache.c
@@ -30,6 +30,7 @@ static int fsck_tree(unsigned char *sha1, void *data, unsigned long size)
size -= len + 20;
mark_needs_sha1(sha1, "blob", file_sha1);
}
+ return 0;
}
static int fsck_commit(unsigned char *sha1, void *data, unsigned long size)
@@ -49,6 +50,7 @@ static int fsck_commit(unsigned char *sha1, void *data, unsigned long size)
mark_needs_sha1(sha1, "commit", parent_sha1);
data += 7 + 40 + 1; /* "parent " + <hex sha1> + '\n' */
}
+ return 0;
}
static int fsck_entry(unsigned char *sha1, char *tag, void *data, unsigned long size)