Remove the 32,767 character limit on the environment block for Start-Process (#14111)

This commit is contained in:
Henry Buckle 2021-03-02 23:05:55 +00:00 committed by Aditya Patwardhan
parent a6e7757777
commit 58b7fe2ec5

View file

@ -2341,10 +2341,6 @@ namespace Microsoft.PowerShell.Commands
// Use Unicode encoding
bytes = Encoding.Unicode.GetBytes(builder.ToString());
if (bytes.Length > 0xffff)
{
throw new InvalidOperationException("EnvironmentBlockTooLong");
}
return bytes;
}