Don't let stderr writes in substituters cause a deadlock
This commit is contained in:
		
							parent
							
								
									4ddd077bfa
								
							
						
					
					
						commit
						470553bd05
					
				
					 1 changed files with 4 additions and 0 deletions
				
			
		|  | @ -1007,6 +1007,10 @@ void LocalStore::startSubstituter(const Path & substituter, RunningSubstituter & | |||
|     fromPipe.create(); | ||||
|     errorPipe.create(); | ||||
| 
 | ||||
|     /* Hack: prevent substituters that write too much to stderr from
 | ||||
|        deadlocking our read() from stdout. */ | ||||
|     fcntl(errorPipe.writeSide, F_SETFL, O_NONBLOCK); | ||||
| 
 | ||||
|     setSubstituterEnv(); | ||||
| 
 | ||||
|     run.pid = maybeVfork(); | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue