diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-04-03 08:43:03 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-04-03 08:43:03 -0700 |
commit | f1ad05f3a524a8750533d8263ceb584a9e7ec573 (patch) | |
tree | 9a7c452694f2718b34ddebf32aacf5a373203d5c /builtin/prune.c | |
parent | Merge branch 'ap/maint-diff-rename-avoid-overlap' into maint-1.8.1 (diff) | |
parent | pack-refs: add fully-peeled trait (diff) | |
download | tgif-f1ad05f3a524a8750533d8263ceb584a9e7ec573.tar.xz |
Merge branch 'jk/fully-peeled-packed-ref' into maint-1.8.1
* jk/fully-peeled-packed-ref:
pack-refs: add fully-peeled trait
pack-refs: write peeled entry for non-tags
use parse_object_or_die instead of die("bad object")
avoid segfaults on parse_object failure
Diffstat (limited to 'builtin/prune.c')
-rw-r--r-- | builtin/prune.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/builtin/prune.c b/builtin/prune.c index 8cb8b9186a..85843d4f17 100644 --- a/builtin/prune.c +++ b/builtin/prune.c @@ -149,9 +149,7 @@ int cmd_prune(int argc, const char **argv, const char *prefix) const char *name = *argv++; if (!get_sha1(name, sha1)) { - struct object *object = parse_object(sha1); - if (!object) - die("bad object: %s", name); + struct object *object = parse_object_or_die(sha1, name); add_pending_object(&revs, object, ""); } else |