lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: LYNX-DEV saving a local file in lynx386 version


From: Leonid Pauzner
Subject: Re: LYNX-DEV saving a local file in lynx386 version
Date: Thu, 4 Dec 1997 14:58:22 +0300 (MSK)

>      * From: "T.E.Dickey" <address@hidden>
>
> > I have noted that when local files are saved using "print" option in lynx
> > 386 version #97, the files are written without the "cr" character at end of
> > lines. Is it a bug or a choice?
> generally MS-DOS stuff gets <cr><lf> on the end if the file is opened
> in text mode, will assume <lf> only if it's opened in binary mode.
>

I think we need text mode for 'p'rinting (? also: bookmark, lynx.rc...)
because we really print the text (currently visible by Lynx),
while binary mode for 'd'ownload option only.

I fact, lynx386 call cp.exe for swapping to temp dir while 'd'ownloading,
so we need to open binary mode at this point.

Leonid.


>      * From: Doug Kaufman <address@hidden>
>
> > Actually it happens that if a current document must be saved using the print
> > option and "save to a local file" suboption, the same document will be saved
> > without the CR character at end of line. Is it possible to restore old
> > situation for dos version? Where (in which source) I can see?
>
> See LYMain.c, about line 560:
> #ifdef DJGPP
>     sock_init();
>     _fmode = O_BINARY;
> #endif
>
> _fmode = O_BINARY sets the default file type to binary on fopen.
>
>                            Doug

reply via email to

[Prev in Thread] Current Thread [Next in Thread]