[296172] Schema causes stack error
diff --git a/bundles/org.eclipse.wst.xsd.core/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.xsd.core/META-INF/MANIFEST.MF
index ea09baa..e7e765e 100644
--- a/bundles/org.eclipse.wst.xsd.core/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.xsd.core/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@
 Bundle-ManifestVersion: 2
 Bundle-Name: %_UI_PLUGIN_NAME
 Bundle-SymbolicName: org.eclipse.wst.xsd.core; singleton:=true
-Bundle-Version: 1.1.101.qualifier
+Bundle-Version: 1.1.102.qualifier
 Bundle-Activator: org.eclipse.wst.xsd.core.internal.XSDCorePlugin
 Bundle-Vendor: %Bundle-Vendor.0
 Bundle-Localization: plugin
diff --git a/bundles/org.eclipse.wst.xsd.core/src-contentmodel/org/eclipse/wst/xsd/contentmodel/internal/XSDVisitor.java b/bundles/org.eclipse.wst.xsd.core/src-contentmodel/org/eclipse/wst/xsd/contentmodel/internal/XSDVisitor.java
index f40e1a4..ad50d3c 100644
--- a/bundles/org.eclipse.wst.xsd.core/src-contentmodel/org/eclipse/wst/xsd/contentmodel/internal/XSDVisitor.java
+++ b/bundles/org.eclipse.wst.xsd.core/src-contentmodel/org/eclipse/wst/xsd/contentmodel/internal/XSDVisitor.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
+ * Copyright (c) 2001, 2009 IBM Corporation and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -11,6 +11,7 @@
 package org.eclipse.wst.xsd.contentmodel.internal;
 
 import java.util.Iterator;
+import java.util.Stack;
 
 import org.eclipse.xsd.XSDAttributeDeclaration;
 import org.eclipse.xsd.XSDAttributeGroupDefinition;
@@ -35,6 +36,7 @@
   }
   
   protected XSDSchema schema;
+  protected Stack particleStack = new Stack();
   
   public void visitSchema(XSDSchema schema)
   {
@@ -156,7 +158,18 @@
   {
     if (particleContent instanceof XSDModelGroupDefinition)
     {
-      visitModelGroupDefinition((XSDModelGroupDefinition) particleContent);
+      XSDModelGroupDefinition modelGroupDef = (XSDModelGroupDefinition) particleContent;
+
+      if (particleStack.contains(modelGroupDef))
+      {
+        return;
+      }
+        
+      particleStack.push(modelGroupDef);
+      
+      visitModelGroupDefinition(modelGroupDef);
+      
+      particleStack.pop();
     }
     else if (particleContent instanceof XSDModelGroup)
     {