Uploaded image for project: 'CFEngine Community'
  1. CFEngine Community
  2. CFE-2152

self referenced variables cause a cf-promises segfault

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Unconfirmed
    • Priority: High
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Evaluation
    • Labels:
      None

      Description

      This is a pretty nasty bug:

      <pre>
      bundle agent main
      {
      vars:
      "list" slist =>

      { @(this.list) }

      ;
      }
      </pre>

      It segfaults. If you backtrace in gdb, it's clear where the bug is:

      <pre>
      ...
      #1926 0x00007ffff7b2a113 in ExpandListEntry (ctx=ctx@entry=0x605160, ns=ns@entry=0x0, scope=scope@entry=0x7ffff7b77874 "this", expandnaked=expandnaked@entry=0x1, entry=...) at expand.c:548
      #1927 0x00007ffff7b2a1f9 in ExpandList (ctx=0x605160, ns=0x0, scope=0x7ffff7b77874 "this", list=<optimized out>, expandnaked=expandnaked@entry=0x1) at expand.c:570
      #1928 0x00007ffff7b2a2e3 in ExpandPrivateRval (ctx=ctx@entry=0x605160, ns=ns@entry=0x0, scope=scope@entry=0x7ffff7b77874 "this", rval_item=rval_item@entry=0x639990, rval_type=<optimized out>) at expand.c:599
      #1929 0x00007ffff7b2a113 in ExpandListEntry (ctx=ctx@entry=0x605160, ns=ns@entry=0x0, scope=scope@entry=0x7ffff7b77874 "this", expandnaked=expandnaked@entry=0x1, entry=...) at expand.c:548
      ...
      </pre>

        Attachments

          Activity

            People

            • Assignee:
              a10003 Eystein Maloy Stenberg
              Reporter:
              tzz Ted Zlatanov
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:

                Summary Panel