summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: cca7081)
raw | patch | inline | side by side (parent: cca7081)
author | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Wed, 29 Jun 2005 16:53:20 +0000 (09:53 -0700) | ||
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Wed, 29 Jun 2005 16:53:20 +0000 (09:53 -0700) |
It can no longer be as verbose, since it doesn't have a good way to
resolve deltas (now that it is purely streaming, it cannot seek around
to read the objects a delta is based on).
But it can check that the thing unpacks cleanly at least as far as pack
syntax goes - all the objects uncompress cleanly, and the pack has the
right final SHA1.
resolve deltas (now that it is purely streaming, it cannot seek around
to read the objects a delta is based on).
But it can check that the thing unpacks cleanly at least as far as pack
syntax goes - all the objects uncompress cleanly, and the pack has the
right final SHA1.
unpack-objects.c | patch | blob | history |
diff --git a/unpack-objects.c b/unpack-objects.c
index 0d15c0038713bfc5bdd732293a434e7921719e48..97d268187497b2ab92e13a656894380b97564469 100644 (file)
--- a/unpack-objects.c
+++ b/unpack-objects.c
case OBJ_TAG: type = "tag"; break;
default: die("bad type %d", kind);
}
- write_object(buf, size, type);
+ if (!dry_run)
+ write_object(buf, size, type);
free(buf);
return 0;
}
use(20);
delta_data = get_data(delta_size);
+ if (dry_run) {
+ free(delta_data);
+ return 0;
+ }
if (!has_sha1_file(base_sha1)) {
add_delta_to_list(base_sha1, delta_data, delta_size);