Merge pull request #283 from Icinga:fix/string_builder_initialization

Fix: String builder creation on older windows machines

Fixes issue on `System.Text.StringBuilder` which fails to initialize properly on some older Windows systems
This commit is contained in:
Lord Hepipud 2021-06-04 13:21:54 +02:00 committed by GitHub
commit d9a66f0f94
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 2 deletions

View file

@ -7,6 +7,17 @@ documentation before upgrading to a new release.
Released closed milestones can be found on [GitHub](https://github.com/Icinga/icinga-powershell-framework/milestones?state=closed).
## 1.6.0 (pending)
[Issue and PRs](https://github.com/Icinga/icinga-powershell-framework/milestone/15?closed=1)
## 1.5.1 (pending)
[Issue and PRs](https://github.com/Icinga/icinga-powershell-framework/milestone/17?closed=1)
### Bugfixes
* [#282](https://github.com/Icinga/icinga-powershell-framework/issues/282) Fixes issue on `System.Text.StringBuilder` which fails to initialize properly on some older Windows systems
## 1.5.0 (2021-06-02)
[Issue and PRs](https://github.com/Icinga/icinga-powershell-framework/milestone/13?closed=1)

View file

@ -397,7 +397,7 @@ function Compare-IcingaPluginThresholds()
}
}
$PluginOutputMessage = [System.Text.StringBuilder]::New();
$PluginOutputMessage = New-Object -TypeName 'System.Text.StringBuilder';
[string]$PluginCurrentValue = [string]::Format(
'{0}',

View file

@ -98,7 +98,7 @@ function New-IcingaCheckPackage()
$UnknownChecks = '';
$CriticalChecks = '';
$WarningChecks = '';
$CheckSummary = [System.Text.StringBuilder]::New();
$CheckSummary = New-Object -TypeName 'System.Text.StringBuilder';
[bool]$HasContent = $FALSE;
# Only apply this to the top parent package