Commit 3979e2a
committed
Fix GetDiffShortStat. It now correctly returns the stat between two revs.
When using the base...head pattern git diff works out the common merge
base and then compare the mergebase to the head revision. This results
in incorrect stats if the you are comparing a y shaped branches
e.g.: sets of revisions. For example on the pull requests view changes
tab when you select since revision, when the last revision just changed
the commit msg the returned content is correctly empty (because there
is no file content change) but the stat is not because the comparasion
is not made between the actual revision heads but their merge head.
Regural /compare/base...head comparisions which also use this function
are not affected by this change because they *themselves* work out the
common merge base and they use *that* to call this function. So they
were doing this anyway instead of relying on this function to compute
the common merge base.
I checked all paths (I think...) that leads to this function and all
calls to this seem to be correct after this change.1 parent c26bb2d commit 3979e2a
1 file changed
+0
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
131 | 131 | | |
132 | 132 | | |
133 | 133 | | |
134 | | - | |
135 | | - | |
136 | 134 | | |
137 | 135 | | |
138 | | - | |
139 | | - | |
140 | 136 | | |
141 | 137 | | |
142 | 138 | | |
| |||
0 commit comments