]> source.dussan.org Git - sonarqube.git/commitdiff
Fix infinite loop in project.r, method ancestor_projects
authorSimon Brandhof <simon.brandhof@sonarsource.com>
Mon, 20 Jun 2016 11:58:55 +0000 (13:58 +0200)
committerSimon Brandhof <simon.brandhof@sonarsource.com>
Mon, 20 Jun 2016 11:59:08 +0000 (13:59 +0200)
server/sonar-web/src/main/webapp/WEB-INF/app/models/project.rb

index 15d50e8682da2cf7689c2fcb2fb2d6236602b87f..90d1931ef848bf7c3fd9d9bc4e017860e6837ea0 100644 (file)
@@ -86,7 +86,7 @@ class Project < ActiveRecord::Base
   # bottom-up array of projects,
   def ancestor_projects
     node, nodes = self, []
-    nodes << node = node.root while node.root
+    nodes << node = node.root while node.root_uuid != node.uuid
     nodes
   end