Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.unix.programmer > #1197
| From | Jasen Betts <jasen@xnet.co.nz> |
|---|---|
| Newsgroups | comp.lang.c, comp.unix.programmer, comp.os.ms-windows.programmer.win32 |
| Subject | Re: Function to determine the number of chars in a FILE buffer |
| Date | 2011-09-01 11:02 +0000 |
| Organization | Dis (not Dat) Organisation |
| Message-ID | <j3nool$e4p$1@reversiblemaps.ath.cx> (permalink) |
| References | <5303ab8c-2dca-4c04-bb88-49e26fc92f96@n11g2000yqh.googlegroups.com> <4E5EBC04.3060103@verizon.net> <a9aa1617-b56b-4da8-9eba-48c094fe0f79@a13g2000yqd.googlegroups.com> |
Cross-posted to 3 groups.
On 2011-09-01, tm <thomas.mertes@gmx.at> wrote: > Without fbufsize() even setting a file to no buffering with > setvbuf() will probably not lead to a solution: An ungetc() may > have happened and there is no way to find out if the next char > read with getc() will be the one provided with ungetc(). Since > a getc() after an ungetc() will not block inputReady() should > return 1 in this case. basically you can't do non blockin IO using the stdio library in a way that's likely to continue to work. try somethine else (eg: glib ) http://developer.gnome.org/glib/stable/glib-IO-Channels.html -- ⚂⚃ 100% natural --- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---
Back to comp.unix.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: Function to determine the number of chars in a FILE buffer tm <thomas.mertes@gmx.at> - 2011-08-31 23:54 -0700
Re: Function to determine the number of chars in a FILE buffer Jasen Betts <jasen@xnet.co.nz> - 2011-09-01 11:02 +0000
Re: Function to determine the number of chars in a FILE buffer tm <thomas.mertes@gmx.at> - 2011-09-01 05:44 -0700
Re: Function to determine the number of chars in a FILE buffer David Schwartz <davids@webmaster.com> - 2011-09-01 04:41 -0700
csiph-web