id	summary	reporter	owner	description	type	status	priority	milestone	version	resolution	keywords	cc
31	Crash when stdin is a terminal but stdout is not.	anonymous		"Haskeline seems to perform wrong operations when the standard output is not a terminal. A small test program is attached. Here are the result it produces when using a terminal as standard output (""a"" is entered manually):

{{{
[glehmann@gbook haskeline]$ runhaskell test.hs
getLine: a
a
haskeline: a
a
}}}

which seem to be the right behavior. When using a different standard output, the program crash:

{{{
[glehmann@gbook haskeline]$ runhaskell test.hs | tee foo
getLine: a
a
test.hs: getTerminalAttributes: illegal operation (Inappropriate ioctl for device)
}}}

and when using a program a standard input, the behavior is the same as getLine, as documented:

{{{
[glehmann@gbook haskeline]$ yes | runhaskell test.hs | tee foo
getLine: y
y
}}}

This problem has been found in a darcs test by Eric Kow - see http://bugs.darcs.net/issue1050
"	task	closed	major		0.3	fixed	03627546	
