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

manage_variable_values_ini "could not select an edit region" error

    XMLWordPrintable

    Details

    • Platform:
      Any

      Description

      If the section name contains metacharacters we get "could not select an edit region" errors
      eg:
      edit_line => manage_variable_values_ini("$(this.bundle).smb_hiddenshare", "hiddenshare$"),

      2016-11-29T14:14:58+0100 error: /default/elections/files/'/etc/samba/smb.conf'/default/manage_variable_values_ini/insert_lines/'writable=no'[2]: The promised line insertion 'writable=no' could not select an edit region in '/etc/samba/smb.conf'

      Proposed fix:

      Escape the $(sectionName) for each INI_section region selection::

      select_region => INI_section(escape("$(sectionName)")),

        Attachments

          Activity

            People

            • Assignee:
              a10042 Nick Anderson
              Reporter:
              ldumaine Luc Dumaine
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Summary Panel