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/grep.c | |
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/grep.c')
-rw-r--r-- | builtin/grep.c | 4 |
1 files changed, 1 insertions, 3 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); |