Skip to content

Commit 6b0e177

Browse files
authored
Merge pull request #529 from Icinga:fix/package_manifest_reader_on_2012r2
Fix: Package manifest reader on Win 2012 R2 Fixes package manifest reader for Icinga for Windows components on Windows 2012 R2 and older.
2 parents 126ac28 + 8ed242a commit 6b0e177

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

doc/100-General/10-Changelog.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ Released closed milestones can be found on [GitHub](https://github.com/Icinga/ic
1111

1212
[Issue and PRs](https://github.com/Icinga/icinga-powershell-framework/milestone/23?closed=1)
1313

14+
### Bugfixes
15+
16+
* [#529](https://github.com/Icinga/icinga-powershell-framework/pull/529) Fixes package manifest reader for Icinga for Windows components on Windows 2012 R2 and older
17+
1418
### Enhancements
1519

1620
* [#40](https://github.com/Icinga/icinga-powershell-framework/issues/40) Adds support to set service recovery for the Icinga Agent and Icinga for Windows service, to restart them in case of a crash or error

lib/core/repository/Read-IcingaPackageManifest.psm1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ function Read-IcingaPackageManifest()
3434
$FileName = $entry.Name.Replace('.psd1', '');
3535
$FilePath = $entry.FullName.Replace($entry.Name, '');
3636
$FileStream = $entry.Open();
37-
$FileReader = [System.IO.StreamReader]::new($FileStream);
37+
$FileReader = New-Object 'System.IO.StreamReader'($FileStream);
3838
$PackageManifestContent = $FileReader.ReadToEnd();
3939
$FileReader.Dispose();
4040

0 commit comments

Comments
 (0)