Two trivial -Wcast-qual fixes

Luiz Fernando N. Capitulino noticed the one in tree-walk.h where
we cast away constness while computing the legnth of a tree
entry.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Junio C Hamano
2007-06-22 23:19:43 -07:00
parent 0ce396431e
commit 63daae47e5
2 changed files with 2 additions and 2 deletions

View File

@ -478,7 +478,7 @@ static struct cache_tree *read_one(const char **buffer, unsigned long *size_p)
if (0 <= it->entry_count) {
if (size < 20)
goto free_return;
hashcpy(it->sha1, (unsigned char*)buf);
hashcpy(it->sha1, (const unsigned char*)buf);
buf += 20;
size -= 20;
}