From b01ca3e3d9d50e3b1b6be4d54c297066675b3a2a Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 11 Apr 2000 14:34:38 +0000 Subject: [PATCH] fixed double eol problem git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@7119 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/textfile.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/common/textfile.cpp b/src/common/textfile.cpp index 89a8e94033..8ae8ee4eba 100644 --- a/src/common/textfile.cpp +++ b/src/common/textfile.cpp @@ -118,6 +118,10 @@ wxString wxTextFile::Translate(const wxString& text, wxTextFileType type) if ( chLast == _T('\r') ) { // Mac line termination result += eol; + + // reset chLast to avoid inserting another eol before the + // next character + chLast = 0; } // add to the current line