commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simonetrip...@apache.org
Subject svn commit: r1305065 - /commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/spanning/DefaultSpanningTreeSourceSelector.java
Date Sun, 25 Mar 2012 15:45:17 GMT
Author: simonetripodi
Date: Sun Mar 25 15:45:16 2012
New Revision: 1305065

URL: http://svn.apache.org/viewvc?rev=1305065&view=rev
Log:
guard Queue consumption via the empty status

Modified:
    commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/spanning/DefaultSpanningTreeSourceSelector.java

Modified: commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/spanning/DefaultSpanningTreeSourceSelector.java
URL: http://svn.apache.org/viewvc/commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/spanning/DefaultSpanningTreeSourceSelector.java?rev=1305065&r1=1305064&r2=1305065&view=diff
==============================================================================
--- commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/spanning/DefaultSpanningTreeSourceSelector.java
(original)
+++ commons/sandbox/graph/trunk/src/main/java/org/apache/commons/graph/spanning/DefaultSpanningTreeSourceSelector.java
Sun Mar 25 15:45:16 2012
@@ -97,7 +97,7 @@ final class DefaultSpanningTreeSourceSel
 
         Graph<V, WE> tmpGraph = new ReverseDeleteGraph<V, WE>( graph, sortedEdge,
visitedEdge );
 
-        for ( int i = 0; i < sortedEdge.size(); i++ ) 
+        while ( !sortedEdge.isEmpty() )
         {
             WE we = sortedEdge.poll();
 



Mime
View raw message