File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed
Public/Src/Engine/Dll/Distribution Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -236,10 +236,18 @@ private void SendBuildRequests()
236236 m_pipCompletionTaskList . Add ( firstItem . Item1 ) ;
237237 m_buildRequestList . Add ( firstItem . Item2 ) ;
238238
239- while ( m_buildRequestList . Count < MaxMessagesPerBatch && m_buildRequests . TryTake ( out var item , EngineEnvironmentSettings . RemoteWorkerSendBuildRequestTimeoutMs . Value ?? 0 ) )
239+ try
240240 {
241- m_pipCompletionTaskList . Add ( item . Item1 ) ;
242- m_buildRequestList . Add ( item . Item2 ) ;
241+ while ( m_buildRequestList . Count < MaxMessagesPerBatch && m_buildRequests . TryTake ( out var item , EngineEnvironmentSettings . RemoteWorkerSendBuildRequestTimeoutMs . Value ?? 0 ) )
242+ {
243+ m_pipCompletionTaskList . Add ( item . Item1 ) ;
244+ m_buildRequestList . Add ( item . Item2 ) ;
245+ }
246+ }
247+ catch ( InvalidOperationException )
248+ {
249+ // We might have disconnected the worker. We should check the loop condition (buildRequests.IsCompleted) again.
250+ continue ;
243251 }
244252
245253 m_currentBatchSize = m_pipCompletionTaskList . Count ;
You can’t perform that action at this time.
0 commit comments