diff options
author | Ivan Timofeev <timofeev.i.s@gmail.com> | 2011-10-23 21:35:00 +0400 |
---|---|---|
committer | Ivan Timofeev <timofeev.i.s@gmail.com> | 2011-10-24 00:16:18 +0400 |
commit | a47a5ed0a5ffd948d48e02e5a9f0e2064096e7d4 (patch) | |
tree | ab094a16e307b04fe9c7815f2e4ba04efd612265 /tools | |
parent | 3d5caa7ce38c9441d05b01c6feaaaa5ff3bd51de (diff) |
always explicitly handle empty string of ranges
Diffstat (limited to 'tools')
-rw-r--r-- | tools/inc/tools/multisel.hxx | 2 | ||||
-rw-r--r-- | tools/source/memtools/multisel.cxx | 10 |
2 files changed, 0 insertions, 12 deletions
diff --git a/tools/inc/tools/multisel.hxx b/tools/inc/tools/multisel.hxx index 8e4879f1c709..47f56f29716f 100644 --- a/tools/inc/tools/multisel.hxx +++ b/tools/inc/tools/multisel.hxx @@ -191,8 +191,6 @@ public: - the string "-" means the sequence i_nMinNumber to i_nMaxNumber - single number that doesn't fit in [i_nMinNumber,i_nMaxNumber] will be ignored - range that doesn't fit in [i_nMinNumber,i_nMaxNumber] will be adjusted - - an empty string as input is valid and will result in the range [min,max] if given - or an empty vector, if not */ static bool getRangesFromString( const rtl::OUString& i_rPageRange, std::vector< sal_Int32 >& o_rPageVector, diff --git a/tools/source/memtools/multisel.cxx b/tools/source/memtools/multisel.cxx index 13275a863673..68a9eacfa3c0 100644 --- a/tools/source/memtools/multisel.cxx +++ b/tools/source/memtools/multisel.cxx @@ -831,16 +831,6 @@ bool StringRangeEnumerator::setRange( const rtl::OUString& i_rNewRange, bool i_b mnCount = 0; maSequence.clear(); - // we love special cases - if( i_rNewRange.getLength() == 0 ) - { - if( mnMin >= 0 && mnMax >= 0 ) - { - insertRange( mnMin, mnMax, mnMin != mnMax, ! i_bStrict ); - } - return true; - } - const sal_Unicode* pInput = i_rNewRange.getStr(); rtl::OUStringBuffer aNumberBuf( 16 ); std::vector< sal_Int32 > aNumbers; |