mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 06:50:54 +07:00
[github] avoid processing the same subgraph multiple times
#IJPL-160204 Fixed (cherry picked from commit f449ea4351689c3dac3b0ea23327addc30e25c1e) GitOrigin-RevId: acb969f34fa2e24347ef1aeeecdb71575d9a9571
This commit is contained in:
committed by
intellij-monorepo-bot
parent
1777cd515d
commit
b2681c056c
@@ -142,7 +142,10 @@ private fun sortCommits(commits: Collection<GHCommit>, lastCommitSha: String): L
|
||||
}
|
||||
checkNotNull(lastCommit) { "Could not determine last commit" }
|
||||
|
||||
val processedCommits = mutableSetOf<String>()
|
||||
fun ImmutableGraph.Builder<GHCommit>.addCommits(commit: GHCommit) {
|
||||
val alreadyProcessed = processedCommits.add(commit.oid)
|
||||
if (alreadyProcessed) return
|
||||
addNode(commit)
|
||||
for (parent in commit.parents) {
|
||||
val parentCommit = commitsBySha[parent.oid]
|
||||
|
||||
Reference in New Issue
Block a user