yaron.keren added a subscriber: sunfish.
yaron.keren added a comment.

The original commit 
http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20100816/106268.html 
by Dan Ghoman says:

"Make raw_fd_ostream consider itself the owner of STDOUT_FILENO when
constructed with an output filename of "-". In particular, allow the
file descriptor to be closed, and close the file descriptor in the
destructor if it hasn't been explicitly closed already, to ensure
that any write errors are detected."

Closing stdout causes not only this problem in the 2nd close (which may be 
worked around) but potentially losing text output depending on who gets to 
close the stream first. Is it normal behaviour for console programs to close 
their stdout?


http://reviews.llvm.org/D13128



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to