lockfile: move documentation to lockfile.h and lockfile.c
[git.git] / blob.c
blob1fcb8e44b00f3b9eedbe92da8abe47c2bebca7c7
1 #include "cache.h"
2 #include "blob.h"
4 const char *blob_type = "blob";
6 struct blob *lookup_blob(const unsigned char *sha1)
8 struct object *obj = lookup_object(sha1);
9 if (!obj)
10 return create_object(sha1, alloc_blob_node());
11 return object_as_type(obj, OBJ_BLOB, 0);
14 int parse_blob_buffer(struct blob *item, void *buffer, unsigned long size)
16 item->object.parsed = 1;
17 return 0;