mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
Fix Get-ChildItem -Path with wildcard char (#9257)
Unescape non-literal, non-glob path before existence checking.
This commit is contained in:
1 parent
259c4dd3f2
commit
f0133bed8e
2 files changed
+18
-2
No files matched your search
@@ -1478,7 +1478,7 @@ namespace System.Management.Automation
|
||||
string originalPath = path;
|
||||
path =
|
||||
Globber.GetProviderPath(
|
||||
path,
|
||||
context.SuppressWildcardExpansion ? path : WildcardPattern.Unescape(path),
|
||||
context,
|
||||
out provider,
|
||||
out drive);
|
||||
@@ -2441,7 +2441,7 @@ namespace System.Management.Automation
|
||||
|
||||
string providerPath =
|
||||
Globber.GetProviderPath(
|
||||
path,
|
||||
context.SuppressWildcardExpansion ? path : WildcardPattern.Unescape(path),
|
||||
context,
|
||||
out provider,
|
||||
out drive);
|
||||
|
||||
Reference in new issue
Block a user