This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Change output stream for printf


> Another approach would be to use fileno(stdout) to get the file
> descriptor underneath stdout (it should be 1). close() it and then
> dup2() the socket into that descriptor. This is how it is done in *NIX
> and it should work in eCos. You may need to do a bit of business to
> flush any data still in the stream buffers.

I seemed to remember something about this not working, which i why i
did not suggest it. Now you have mentioned it, i went googling. Its
probably worth reading the thread:

http://sources.redhat.com/ml/ecos-discuss/2003-04/msg00135.html

        Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]