lua-users home
lua-l archive

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


Hi Sean:



On Fri, Feb 21, 2014 at 11:28 AM, Sean Conner <sean@conman.org> wrote:
>> >> >   How is discarding '\015' any different from mapping "\015\012" to "\012"?
>> >> Isn't obvious? The simpler example: '\015' => '', some more:
>> >> 'ab\015cd\015\012' => abcd\n vs. ab\rcd\n
>   How I should have answered that was, "no, that was not obvious to me."  In
> all my years of programming, I had not come across a text file with both CR
> and LF that weren't paired together.

Well, I did use the example as I was bitten with one of this files
which used double line print for doing understrike/overstrike on
daisy-wheel printers ( backspace for single char overstrike, optimized
to CR plus whole line for longer ones ).


>> Are you trying to kid me again? My buffer will contain a terminating
>> null, that is guaranteed by fgets. Where is it?
>   My mistake.  I am sorry about that.

I apologise, I'm feeling a bit tense.

Francisco Olarte.