diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-05-30 07:04:07 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-05-30 07:04:07 +0200 |
commit | 50f08db5941755b69012378bfc86f6b8ee98edf4 (patch) | |
tree | d403a1dbf522fdaab4cf6b9b508a08b3965828e2 /builtin/index-pack.c | |
parent | Merge branch 'rs/no-null-ptr-arith-in-fast-export' (diff) | |
parent | BUG_exit_code: fix sparse "symbol not declared" warning (diff) | |
download | git-50f08db5941755b69012378bfc86f6b8ee98edf4.tar.xz git-50f08db5941755b69012378bfc86f6b8ee98edf4.zip |
Merge branch 'js/use-bug-macro'
Developer support update, by using BUG() macro instead of die() to
mark codepaths that should not happen more clearly.
* js/use-bug-macro:
BUG_exit_code: fix sparse "symbol not declared" warning
Convert remaining die*(BUG) messages
Replace all die("BUG: ...") calls by BUG() ones
run-command: use BUG() to report bugs, not die()
test-tool: help verifying BUG() code paths
Diffstat (limited to 'builtin/index-pack.c')
-rw-r--r-- | builtin/index-pack.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/builtin/index-pack.c b/builtin/index-pack.c index 59130e8ecb..b3a5abcf2b 100644 --- a/builtin/index-pack.c +++ b/builtin/index-pack.c @@ -869,7 +869,7 @@ static void sha1_object(const void *data, struct object_entry *obj_entry, if (obj->type == OBJ_COMMIT) { struct commit *commit = (struct commit *) obj; if (detach_commit_buffer(commit, NULL) != data) - die("BUG: parse_object_buffer transmogrified our buffer"); + BUG("parse_object_buffer transmogrified our buffer"); } obj->flags |= FLAG_CHECKED; } @@ -1018,7 +1018,7 @@ static struct base_data *find_unresolved_deltas_1(struct base_data *base, if (!compare_and_swap_type(&child->real_type, OBJ_REF_DELTA, base->obj->real_type)) - die("BUG: child->real_type != OBJ_REF_DELTA"); + BUG("child->real_type != OBJ_REF_DELTA"); resolve_delta(child, base, result); if (base->ref_first == base->ref_last && base->ofs_last == -1) |