Permalink
Browse files

#1012 : Add check to cap the timeout to int max.

  • Loading branch information...
michaellwest committed Jun 2, 2018
1 parent cd5e87f commit df91d4fca0f5a1ebc246b26df9df02050eee0327
Showing with 1 addition and 1 deletion.
  1. +1 −1 Modules/SPE/New-ScriptSession.ps1
@@ -115,7 +115,7 @@ function New-ScriptSession {
}
if ($Timeout -gt 0) {
$serviceProxy.Timeout = $Timeout * 1000
$serviceProxy.Timeout = [math]::Min($Timeout * 1000, [int]::MaxValue)
}
if (!$serviceProxy.Url.StartsWith($uri.Scheme + "://")) {

0 comments on commit df91d4f

Please sign in to comment.