diff options
author | Stefan Beller <sbeller@google.com> | 2017-06-29 17:06:46 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-06-30 13:13:01 -0700 |
commit | f2d2a5def088b474586eedfa4fa547bc2c955bb9 (patch) | |
tree | c21357d026bc9626f762b608637a0d5e80413d5c /diff.c | |
parent | Merge branch 'sb/hashmap-customize-comparison' into sb/diff-color-move (diff) | |
download | tgif-f2d2a5def088b474586eedfa4fa547bc2c955bb9.tar.xz |
diff.c: readability fix
We already have dereferenced 'p->two' into a local variable 'two'.
Use that.
Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff.c')
-rw-r--r-- | diff.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -3282,8 +3282,8 @@ static void run_diff(struct diff_filepair *p, struct diff_options *o) const char *other; const char *attr_path; - name = p->one->path; - other = (strcmp(name, p->two->path) ? p->two->path : NULL); + name = one->path; + other = (strcmp(name, two->path) ? two->path : NULL); attr_path = name; if (o->prefix_length) strip_prefix(o->prefix_length, &name, &other); |