diff options
author | Junio C Hamano <gitster@pobox.com> | 2009-07-24 09:27:09 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-07-24 09:27:09 -0700 |
commit | f87dd2152a6941dfa7f3ddaf599bc30f58562a98 (patch) | |
tree | 308c66f7be4942b01b468e958cb7c9c64dd39131 /refs.c | |
parent | 4aacaeb3dc82bb6479e70e120053dc27a399460e (diff) | |
parent | 01ae841ccf3aa5d5331a4e6aed6122fee6617740 (diff) | |
download | git-f87dd2152a6941dfa7f3ddaf599bc30f58562a98.tar.gz |
Merge branch 'maint'
* maint:
SunOS grep does not understand -C<n> nor -e
Fix export_marks() error handling.
git branch: clean up detached branch handling
git branch: avoid unnecessary object lookups
git branch: fix performance problem
do_one_ref(): null_sha1 check is not about broken ref
Conflicts:
Makefile
Diffstat (limited to 'refs.c')
-rw-r--r-- | refs.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -531,9 +531,10 @@ static int do_one_ref(const char *base, each_ref_fn fn, int trim, { if (strncmp(base, entry->name, trim)) return 0; + /* Is this a "negative ref" that represents a deleted ref? */ + if (is_null_sha1(entry->sha1)) + return 0; if (!(flags & DO_FOR_EACH_INCLUDE_BROKEN)) { - if (is_null_sha1(entry->sha1)) - return 0; if (!has_sha1_file(entry->sha1)) { error("%s does not point to a valid object!", entry->name); return 0; |