From: mortee Date: 2007-10-12T12:55:11+09:00 Subject: Re: Ignore printout Fredrik wrote: > I am using a compiled C-code in my Ruby program. The problem is that > the C-code prints some messages that I don't want to show in my Ruby > program. What would be the best way to get rid of these printouts? > > I don't want to get into the original C-code and take away the print > commands since that is not my code. Are the printouts sent directly to > standard output, meaning there is no way for Ruby to interfere? You may try to redirect $stdout while the C code runs - I'm not sure this will work, but it's worth a try. mortee