aboutsummaryrefslogtreecommitdiff
path: root/fast-import.c
diff options
context:
space:
mode:
authorJonathan Nieder <jrnieder@gmail.com>2011-02-28 15:16:59 -0600
committerJonathan Nieder <jrnieder@gmail.com>2011-02-28 15:25:12 -0600
commit6288e3e180c0b911e6f7062f1e744a25568f7d22 (patch)
tree5d1cb4f74f1a5943433c3a3fa0fb43fad45952ea /fast-import.c
parenta62bbf8f01c6b19cd1a5cf92a98f612176aa2b67 (diff)
downloadgit-6288e3e180c0b911e6f7062f1e744a25568f7d22.tar.gz
git-6288e3e180c0b911e6f7062f1e744a25568f7d22.tar.xz
fast-import: make code "-Wpointer-arith" clean
The dereference() function to peel a tree-ish and find the underlying tree expects arithmetic to (void *) to work on byte addresses. We should be reading the text of objects through a char * anyway. Noticed-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Diffstat (limited to 'fast-import.c')
-rw-r--r--fast-import.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fast-import.c b/fast-import.c
index 6c37b8400..e1268b8cb 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -2848,7 +2848,7 @@ static struct object_entry *dereference(struct object_entry *oe,
unsigned char sha1[20])
{
unsigned long size;
- void *buf = NULL;
+ char *buf = NULL;
if (!oe) {
enum object_type type = sha1_object_info(sha1, NULL);
if (type < 0)