[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: CString to CStringA conversion and other questions :)

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Mon, 20 Aug 2012 22:13:28 +0200

On 20.08.2012 21:19, Oto BREZINA wrote:
> On 2012-08-20 21:03, Stefan Küng wrote:
>> On 20.08.2012 20:40, Oto BREZINA wrote:
>>
>>>>> 7.
>>>>> If I read code correctly On CFileTextLines::CheckLineEndings you detect
>>>>> EOL_LFCR, but in CFileTextLines::Load this is one is decoded as EOL_LF
>>>>> and EOL_CR or EOL_CRLF.
>>>>> Is this intentional?
>>>>> I guess EOL_LFCR is too rare to be really wanted, but why to detect it
>>>>> in Check then. This makes all EOL_AUTOLINE EOL_LFCR.
>>>> I don't understand what you mean here.
>>>> In Load(), the line endings are checked by calling CheckLineEndings(),
>>>> there's no separate detection.
>>> CheckLineEndings can detect EOL_LFCR, Load not. Is this what you want?
>> Load() calls CheckLineEndings(), which can detect EOL_LFCR.
>> Or am I missing something here?
> You are right - I miss this point so I was not clear enough:
>
> Load() on begining calls CheckLineEndings() to select right AUTO EOL -
> is support four OELs.
> But when analyzing file text it does not recognize EOL_LFCR.
>
> for (int i = 0; i<nReadChars; ++i)
> '\r' + '\n' -> EOL_CRLF
> '\r' -> EOL_CR
> '\n' -> EOL_LF
>
> '\n' + '\r' is not recognized for EOL_LFCR here.

in that case, that would be a bug.

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.net
------------------------------------------------------
http://tortoisesvn.tigris.org/ds/viewMessage.do?dsForumId=757&dsMessageId=2999700
To unsubscribe from this discussion, e-mail: [dev-unsubscribe_at_tortoisesvn.tigris.org].
Received on 2012-08-20 22:14:00 CEST

This is an archived mail posted to the TortoiseSVN Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.