Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Guido Draheim
Guido Draheim wrote: > The "b" is an ansi-C requirement, however there may be some systems > that are simply not compliant. [...] I just > found second hand information that some DEC ultrix libc did barf > at "b". I did a bit of web digging, and I found first hand information in a tex package da

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Paul Eggert
> From: Akim Demaille <[EMAIL PROTECTED]> > User-Agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands) > > But the question remains open :) I certainly recall reports of hosts where fopen (..."wb") did not work. However, I don't recall which hosts they were. I briefly looked around the

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Earnie Boyd
--- Akim Demaille <[EMAIL PROTECTED]> wrote: > > "Earnie" == Earnie Boyd <[EMAIL PROTECTED]> writes: > > Earnie> Lars, just to satisfy my curiosity please send me the output > Earnie> of `cygcheck -s -r -v'. > > What's this? It is a tool developed by the Cygwin team to report on the use

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Guido Draheim
Peter Eisentraut wrote: > Akim Demaille writes: > > Does anybody know whether using fopen (foo, "wb") is portable? > Extremely doubtful. The "b" is an ansi-C requirement, however there may be some systems that are simply not compliant. AFAICS these are quite old, somewhere in the eighties or so -

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Alexandre Oliva
On Nov 16, 2000, Akim Demaille <[EMAIL PROTECTED]> wrote: > Does anybody know whether using fopen (foo, "wb") is portable? I recall having read about it in ``The C Primer'', when I first learned C back in 198x (for a small value of x). -- Alexandre Oliva Enjoy Guarana', see http://www.ic.uni

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Akim Demaille
> "Peter" == Peter Eisentraut <[EMAIL PROTECTED]> writes: Peter> * Do not print an end-of-line at all. !!! Of course! Thanks! But the question remains open :)

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Peter Eisentraut
Akim Demaille writes: > Does anybody know whether using fopen (foo, "wb") is portable? Extremely doubtful. In this particular case you can work around by using open() and write() and define O_BINARY to be 0 if not defined already. Other possible approaches: * Focus on avoiding getting the \r

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread John W. Eaton
On 16-Nov-2000, Earnie Boyd <[EMAIL PROTECTED]> wrote: | --- Akim Demaille <[EMAIL PROTECTED]> wrote: | | > Does anybody know whether using fopen (foo, "wb") is portable? Gary | > uses a test for this, but I don't know if it's really needed. A grep | > on the packages I have at hand show this:

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Akim Demaille
> "Earnie" == Earnie Boyd <[EMAIL PROTECTED]> writes: Earnie> Lars, just to satisfy my curiosity please send me the output Earnie> of `cygcheck -s -r -v'. What's this? I'm looking for all the possible uname and the like which we could include in the config.log. Currently, you have: This

Re: Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Earnie Boyd
--- Akim Demaille <[EMAIL PROTECTED]> wrote: > > | On Thu, Nov 16, 2000 at 12:51:05PM +0100, Akim Demaille wrote: > | : > | : | -[FILE *f = fopen ("conftestval", "w"); > | : | +[FILE *f = fopen ("conftestval", "wb"); > | : > | : Portable? > | > | Not really my cup of tea, but (from fopen(3) on

Portability of fopen (foo, "wb") (Was: bug in AC_COMPUTE_INT)

2000-11-16 Thread Akim Demaille
| On Thu, Nov 16, 2000 at 12:51:05PM +0100, Akim Demaille wrote: | : | : | -[FILE *f = fopen ("conftestval", "w"); | : | +[FILE *f = fopen ("conftestval", "wb"); | : | : Portable? | | Not really my cup of tea, but (from fopen(3) on Linux): | | # The mode string can also include the letter ``b