Browse Source
Each time the longest common substring is found the diff algorithm recurses to reprocess the regions before and after the common string. Large files with many edits can trigger StackOverflowError as the algorithm attempts to process a deeply split tree of regions. This is especially prone to happen in servers where the Java stack size may have been limited to 1M or even 256K. To keep edits produced in order a queue is used to process edits in a depth-first strategy. Change-Id: Iae7260c6934efdffac7c7bee4d3633a8208924f7stable-3.5
Shawn Pearce
10 years ago
1 changed files with 14 additions and 6 deletions
Loading…
Reference in new issue