merge-recursive: rename locals 'o' and 'a' to 'obuf' and 'abuf'

Since we want to replace oid,mode pairs with a single diff_filespec, we will soon want to be able to use the names 'o', 'a', and 'b' for the three different file versions. Rename some local variables in blob_unchanged() that would otherwise conflict. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Elijah Newren committed Apr 5, 2019 at 08:00 UTC 93a02c5553a293aa0ae34293304332dbc0fee431
1 file changed +10 -8
merge-recursive.c
+10 -8
@@ -3031,9 +3031,10 @@ static int blob_unchanged(struct merge_options *opt,
3031 unsigned a_mode,
3032 int renormalize, const char *path)
3033 {
3034 - struct strbuf o = STRBUF_INIT;
3035 - struct strbuf a = STRBUF_INIT;
3034 + struct strbuf obuf = STRBUF_INIT;
3035 + struct strbuf abuf = STRBUF_INIT;
3036 int ret = 0; /* assume changed for safety */
3037 + const struct index_state *idx = opt->repo->index;
3038
3039 if (a_mode != o_mode)
3040 return 0;
@@ -3043,20 +3044,21 @@ static int blob_unchanged(struct merge_options *opt,
3044 return 0;
3045
3046 assert(o_oid && a_oid);
3046 - if (read_oid_strbuf(opt, o_oid, &o) || read_oid_strbuf(opt, a_oid, &a))
3047 + if (read_oid_strbuf(opt, o_oid, &obuf) ||
3048 + read_oid_strbuf(opt, a_oid, &abuf))
3049 goto error_return;
3050 /*
3051 * Note: binary | is used so that both renormalizations are
3052 * performed. Comparison can be skipped if both files are
3053 * unchanged since their sha1s have already been compared.
3054 */
3053 - if (renormalize_buffer(opt->repo->index, path, o.buf, o.len, &o) |
3054 - renormalize_buffer(opt->repo->index, path, a.buf, a.len, &a))
3055 - ret = (o.len == a.len && !memcmp(o.buf, a.buf, o.len));
3055 + if (renormalize_buffer(idx, path, obuf.buf, obuf.len, &obuf) |
3056 + renormalize_buffer(idx, path, abuf.buf, abuf.len, &abuf))
3057 + ret = (obuf.len == abuf.len && !memcmp(obuf.buf, abuf.buf, obuf.len));
3058
3059 error_return:
3058 - strbuf_release(&o);
3059 - strbuf_release(&a);
3060 + strbuf_release(&obuf);
3061 + strbuf_release(&abuf);
3062 return ret;
3063 }
3064