Use blob_, commit_, tag_, and tree_type throughout.

This replaces occurences of "blob", "commit", "tag", and "tree",
where they're really used as type specifiers, which we already
have defined global constants for.

Signed-off-by: Peter Eriksen <s022018@student.dtu.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Peter Eriksen
2006-04-02 14:44:09 +02:00
committed by Junio C Hamano
parent fc9957b005
commit 8e44025925
23 changed files with 102 additions and 69 deletions

View File

@ -1,5 +1,6 @@
#include "cache.h"
#include "commit.h"
#include "blob.h"
#include "diff.h"
#include "diffcore.h"
#include "quote.h"
@ -104,7 +105,7 @@ static char *grab_blob(const unsigned char *sha1, unsigned long *size)
return xcalloc(1, 1);
}
blob = read_sha1_file(sha1, type, size);
if (strcmp(type, "blob"))
if (strcmp(type, blob_type))
die("object '%s' is not a blob!", sha1_to_hex(sha1));
return blob;
}