OSProcess.st
changeset 21226 568b192939c7
parent 21223 bebca95ca864
child 21252 1b7c2d5523d5
child 21332 18ca24f32565
equal deleted inserted replaced
21225:3d24c11b1f9b 21226:568b192939c7
   385                             |data|
   385                             |data|
   386 
   386 
   387                             data := shuffledStream nextLine.
   387                             data := shuffledStream nextLine.
   388                             data notNil ifTrue:[
   388                             data notNil ifTrue:[
   389                                 aStream nextPutLine:data
   389                                 aStream nextPutLine:data
   390                             ] .
   390                             ].
   391                         ].
   391                         ].
   392                     ] ifFalse:[
   392                     ] ifFalse:[
   393                         shuffledStream copyToEndInto:aStream.
   393                         shuffledStream copyToEndInto:aStream.
   394                     ].
   394                     ].
   395                 ] ensure:[
   395                 ] ensure:[
   465     shufflerProcesses := OrderedCollection new:4.
   465     shufflerProcesses := OrderedCollection new:4.
   466     streamsToClose := OrderedCollection new:2.
   466     streamsToClose := OrderedCollection new:2.
   467 
   467 
   468     externalInStream := self setupShufflerForInput:inStream.
   468     externalInStream := self setupShufflerForInput:inStream.
   469     externalAuxStream := self setupShufflerForInput:auxStream.
   469     externalAuxStream := self setupShufflerForInput:auxStream.
       
   470     externalOutStream := self setupShufflerForOutput:outStream.
   470     errorStream == outStream ifTrue:[
   471     errorStream == outStream ifTrue:[
   471         externalErrorStream := externalOutStream := self setupShufflerForOutput:errorStream.
   472         externalErrorStream := externalOutStream.
   472     ] ifFalse:[
   473     ] ifFalse:[
   473         externalErrorStream := self setupShufflerForOutput:errorStream.
   474         externalErrorStream := self setupShufflerForOutput:errorStream.
   474         externalOutStream := self setupShufflerForOutput:outStream.
       
   475     ].
   475     ].
   476 
   476 
   477     "start the command"
   477     "start the command"
   478     finishSema := EventSemaphore new.
   478     finishSema := EventSemaphore new.
   479 
   479 
   487                         auxFrom:externalAuxStream
   487                         auxFrom:externalAuxStream
   488                         environment:environment
   488                         environment:environment
   489                         inDirectory:directory
   489                         inDirectory:directory
   490                         newPgrp:newPgrp
   490                         newPgrp:newPgrp
   491                         showWindow:showWindow.
   491                         showWindow:showWindow.
   492 
       
   493             pid
       
   494         ] 
   492         ] 
   495         action:[:status |
   493         action:[:status |
   496             status stillAlive ifFalse:[
   494             status stillAlive ifFalse:[
   497                 exitStatus := status.
   495                 exitStatus := status.
   498                 pid notNil ifTrue:[
   496                 pid notNil ifTrue:[