From e3f289d980862bdfa4def521eef1a790b9e731b7 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Sun, 18 Sep 2011 21:41:14 +0100 Subject: ByteString->rtl::OString --- tools/bootstrp/prj.cxx | 9 ++++----- tools/inc/bootstrp/prj.hxx | 1 - 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'tools') diff --git a/tools/bootstrp/prj.cxx b/tools/bootstrp/prj.cxx index d38cbd1c3ce2..391f4a6b142f 100644 --- a/tools/bootstrp/prj.cxx +++ b/tools/bootstrp/prj.cxx @@ -71,12 +71,11 @@ rtl::OString SimpleConfig::getNext() rtl::OString SimpleConfig::GetNextLine() { - aFileStream.ReadLine ( aTmpStr ); - if ( aTmpStr.Search( "#" ) == 0 ) + rtl::OString aTmpStr; + aFileStream.ReadLine(aTmpStr); + if (aTmpStr[0] == '#') return rtl::OString('\t'); - aTmpStr.EraseLeadingAndTrailingChars(); - aTmpStr.SearchAndReplaceAll(' ', '\t'); - return aTmpStr; + return aTmpStr.trim().replace(' ', '\t'); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/tools/inc/bootstrp/prj.hxx b/tools/inc/bootstrp/prj.hxx index 35896065d159..62d97272c2c5 100644 --- a/tools/inc/bootstrp/prj.hxx +++ b/tools/inc/bootstrp/prj.hxx @@ -43,7 +43,6 @@ class SimpleConfig { SvFileStream aFileStream; - ByteString aTmpStr; ByteString aStringBuffer; rtl::OString GetNextLine(); -- cgit