apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jonathan Leffler <jonathan.leff...@gmail.com>
Subject Re: Newline chars in Win and OS/2
Date Thu, 10 Sep 2009 13:06:02 GMT
On Thu, Sep 10, 2009 at 2:37 AM, Yuri V. Vishnevskiy <
yuri.vishnevskiy@gmail.com> wrote:

> is this correct behaviour of the apr_file_puts function which prints a
> "bla-bla-bla \n" string to file _without_ conversion of the \n to \r\n
> sequence under Windows ans OS/2 ?
>

If the file is opened in text mode, not binary mode, then the o/s library
should be handling the newline to CRLF conversion automatically.

If that doesn't happen, then (1) is the file opened in binary mode and (2)
does that mean APR has to deal with aberrant implementations of the C
standard I/O library on basic functionality?

-- 
Jonathan Leffler <jonathan.leffler@gmail.com>  #include <disclaimer.h>
Guardian of DBD::Informix - v2008.0513 - http://dbi.perl.org
"Blessed are we who can laugh at ourselves, for we shall never cease to be
amused."

Mime
View raw message