ReceiveCommits: parseBody before getFooterLines
The RevWalk in ReceiveCommits is used for walking commits in various places, some of which call parseBody on each commit and some that don't. The call to RevWalk#getFooterLines on line 1707 was clearly not preceded by a call to parseBody earlier in the same block; the fact that it managed to avoid throwing NPE most of the time is pure luck. We have a report of NPEs in the wild from this line. Make the obvious fix first, and if we end up having time we can go back and debug later how it happened. Change-Id: I5728bb6d46ae4c121c096379b07660f01f86d640
This commit is contained in:
@@ -1650,6 +1650,7 @@ public class ReceiveCommits {
|
||||
break;
|
||||
}
|
||||
total++;
|
||||
rp.getRevWalk().parseBody(c);
|
||||
String name = c.name();
|
||||
groupCollector.visit(c);
|
||||
Collection<Ref> existingRefs = existing.get(c);
|
||||
|
||||
Reference in New Issue
Block a user