Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-12848

Display macro does not stop infinite loop

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 7.4-milestone-1
    • 7.2
    • Display
    • None
    • Unit
    • Unknown
    • N/A
    • N/A

    Description

      The display macro contains code that should prevent a recursive infinite loop, but that check is not currently working and instead the user experiences a StackOverflow error.

      Steps to reproduce:
      1. Create a page with the path "Main.Display1.WebHome" with the following content:

      display 1

      {{display reference="Main.Display2.WebHome" /}}
      

      2. Create a page with the path "Main.Display2.WebHome" with the following content:

      display 2

      {{display reference="Main.Display1.WebHome" /}}
      

      Expected:
      A red box on the page with the macro exception "MacroExecutionException: Found recursive inclusion of document"

      Actual:
      A red box on the page with the generic exception "StackOverflowException: stack too deep"

      Attachments

        Activity

          People

            tmortagne Thomas Mortagne
            Peter Peter Nix
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: