]> source.dussan.org Git - jgit.git/commitdiff
Stack Overflow in EGit History View 83/1183/1
authorMathias Kinzler <mathias.kinzler@sap.com>
Wed, 28 Jul 2010 09:46:05 +0000 (11:46 +0200)
committerMathias Kinzler <mathias.kinzler@sap.com>
Wed, 28 Jul 2010 09:46:05 +0000 (11:46 +0200)
This is caused by a recursion in PlotWalk.getTags().
As a hotfix, the sort was simply removed. The sort
must be re-implemented so that parseAny() is not called
again (currently, this happens in the PlotRefComparator).

Change-Id: I060d26fda8a75ac803acaf89cfb7d3b4317328f3
Signed-off-by: Mathias Kinzler <mathias.kinzler@sap.com>
Signed-off-by: Christian Halstrick <christian.halstrick@sap.com>
org.eclipse.jgit/src/org/eclipse/jgit/revplot/PlotWalk.java

index 476592f5d95d95483d937d19c349d036a0cde52f..666cb0287bed6de1e010a50b80490da609aa0d6d 100644 (file)
@@ -45,7 +45,6 @@
 package org.eclipse.jgit.revplot;
 
 import java.io.IOException;
-import java.util.Arrays;
 import java.util.Collection;
 import java.util.Comparator;
 import java.util.Map;
@@ -108,7 +107,9 @@ public class PlotWalk extends RevWalk {
                        tags = null;
                else {
                        tags = list.toArray(new Ref[list.size()]);
-                       Arrays.sort(tags, new PlotRefComparator());
+                       // TODO hotfix, this results in a loop and consequently stack overflow
+                       // when opening the history view in EGit
+                       // Arrays.sort(tags, new PlotRefComparator());
                }
                return tags;
        }