Skip to content

Unexpected symbol/character added to end of variable value when mergemode => clobber #100

Description

@dtvlinux

Describe the Bug

When declaring a variable using mergemode clobber, the value in the registry has the following character appended at the end:

倀

For example, value data would show as:

C:\software\tomcat倀

Expected Behavior

The registry value data should display as:

C:\software\tomcat

Steps to Reproduce

Declare resource as follows:

windows_env {'CATALINA_HOME':
  ensure    => present,
  variable  => 'CATALINA_HOME',
  value     => 'C:\software\tomcat',
  mergemode => clobber,
}

After puppet run, go to registry location below to view applied values for variable:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment

Environment

  • Puppet Agent Version: 8.4.0
  • Platform: Windows Server 2016

Additional Context

Screenshot of the issue:

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions