Re: [LIP] std::cin.readsome(...) and std::cin.rdbuf()->in_avail()

"Josy P. Pullockara" <[email protected]>
Newsgroups gmane.user-groups.linux.india.programmers
Organization National Aerospace Laboratories
Message-ID <[email protected]>
On Wed, 2003-12-03 at 10:41, Binand Sethumadhavan wrote:
> I think you need an unbuffered stream. In C/stdio, there is a function
> setbuf().
> 
> setbuf (stdin, NULL); /* makes stdin unbuffered */

setbuf(stdin, NULL); works better than std::cin.rdbuf()->pubsetbuf(0,0);

Thank you.
-- 
Josy P. Pullockara <[email protected]>
National Aerospace Laboratories



-------------------------------------------------------
This SF.net email is sponsored by OSDN's Audience Survey.
Help shape OSDN's sites and tell us what you think. Take this
five minute survey and you could win a $250 Gift Certificate.
http://www.wrgsurveys.com/2003/osdntech03.php?site=8
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.