diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-01-27 08:00:05 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-01-27 12:59:47 +0000 |
commit | 58d4275efae7fc0f3e97c02d79b67cf688052e81 (patch) | |
tree | 9bef151d3dbb2df63fa06ad97896a4215cccb417 /idl | |
parent | 04a32c98be8b890689699068a6147d836d3b2689 (diff) |
make idl ByteString free
Diffstat (limited to 'idl')
-rw-r--r-- | idl/source/objects/types.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/idl/source/objects/types.cxx b/idl/source/objects/types.cxx index 368e06231883..391cdaba8c43 100644 --- a/idl/source/objects/types.cxx +++ b/idl/source/objects/types.cxx @@ -1870,15 +1870,13 @@ void SvMetaTypeEnum::ReadContextSvIdl( SvIdlDataBase & rBase, if( bOk ) { if( 0 == aEnumValueList.Count() ) + { // the first aPrefix = aEnumVal->GetName().getString(); + } else { - rtl::OString sCommonPrefix = getCommonSubPrefix(aPrefix, aEnumVal->GetName().getString()); - sal_uInt16 nPos = ByteString(aPrefix).Match( aEnumVal->GetName().getString() ); - if( nPos != aPrefix.getLength() && nPos != STRING_MATCH ) - aPrefix = aPrefix.copy(0, nPos); - assert(sCommonPrefix == aPrefix); + aPrefix = getCommonSubPrefix(aPrefix, aEnumVal->GetName().getString()); } aEnumValueList.Append( aEnumVal ); } |