summaryrefslogtreecommitdiff
path: root/sha1_file.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-21 01:49:41 (GMT)
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-21 01:49:41 (GMT)
commit860edf7a710245ac748ada2ae3c0581a79f51f55 (patch)
tree121575fff4c32abcbf484331cd813b444f32c62b /sha1_file.c
parent32347c375250fd470973a5d76185cac718955fd5 (diff)
downloadgit-860edf7a710245ac748ada2ae3c0581a79f51f55.zip
git-860edf7a710245ac748ada2ae3c0581a79f51f55.tar.gz
git-860edf7a710245ac748ada2ae3c0581a79f51f55.tar.bz2
Fix up some problems from the commit->tree helper patch
Diffstat (limited to 'sha1_file.c')
-rw-r--r--sha1_file.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sha1_file.c b/sha1_file.c
index 7b7b65d..6f7228e 100644
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -174,7 +174,7 @@ void *read_tree_with_tree_or_commit_sha1(const unsigned char *sha1,
void *buffer;
unsigned long isize;
int was_commit = 0;
- char tree_sha1[20];
+ unsigned char tree_sha1[20];
buffer = read_sha1_file(sha1, type, &isize);
@@ -197,7 +197,7 @@ void *read_tree_with_tree_or_commit_sha1(const unsigned char *sha1,
*/
if (!buffer || strcmp(type, "tree")) {
free(buffer);
- return;
+ return NULL;
}
*size = isize;