diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-04-03 09:18:01 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-04-03 09:18:01 -0700 |
commit | 92e0d916326de103e463f9ffcfcd99ec1f3a9dc0 (patch) | |
tree | 91c7fc235e4d52169b13602eeedbc9c42b407440 /builtin | |
parent | Update draft release notes to 1.8.2.1 (diff) | |
parent | Start preparing for 1.8.1.6 (diff) | |
download | tgif-92e0d916326de103e463f9ffcfcd99ec1f3a9dc0.tar.xz |
Sync with 1.8.1 maintenance track
* maint-1.8.1:
Start preparing for 1.8.1.6
git-tag(1): we tag HEAD by default
Fix revision walk for commits with the same dates
t2003: work around path mangling issue on Windows
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
entry: fix filter lookup
t2003: modernize style
name-hash.c: fix endless loop with core.ignorecase=true
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/grep.c | 4 | ||||
-rw-r--r-- | builtin/prune.c | 4 |
2 files changed, 2 insertions, 6 deletions
diff --git a/builtin/grep.c b/builtin/grep.c index 8025964987..159e65d47a 100644 --- a/builtin/grep.c +++ b/builtin/grep.c @@ -820,9 +820,7 @@ int cmd_grep(int argc, const char **argv, const char *prefix) unsigned char sha1[20]; /* Is it a rev? */ if (!get_sha1(arg, sha1)) { - struct object *object = parse_object(sha1); - if (!object) - die(_("bad object %s"), arg); + struct object *object = parse_object_or_die(sha1, arg); if (!seen_dashdash) verify_non_filename(prefix, arg); add_object_array(object, arg, &list); 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 |