sw/source/core/unocore/unofield.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
New commits: commit 4a8f0d4ee9b144d215378582f02f788327e8f502 Author: Matteo Casalin <matteo.casa...@yahoo.com> AuthorDate: Sun Feb 3 18:33:13 2019 +0100 Commit: Matteo Casalin <matteo.casa...@yahoo.com> CommitDate: Mon Feb 4 23:08:05 2019 +0100 Use indexed getToken() Change-Id: I371ff95ff9d05e0c57844f99c222165e55aa51e8 Reviewed-on: https://gerrit.libreoffice.org/67332 Tested-by: Jenkins Reviewed-by: Matteo Casalin <matteo.casa...@yahoo.com> diff --git a/sw/source/core/unocore/unofield.cxx b/sw/source/core/unocore/unofield.cxx index a75abdc77046..7aca6eb4ff03 100644 --- a/sw/source/core/unocore/unofield.cxx +++ b/sw/source/core/unocore/unofield.cxx @@ -2660,8 +2660,8 @@ static SwFieldIds lcl_GetIdByName( OUString& rName, OUString& rTypeName ) rName = rName.copy(RTL_CONSTASCII_LENGTH(COM_TEXT_FLDMASTER_CC)); SwFieldIds nResId = SwFieldIds::Unknown; - sal_Int32 nFound = 0; - rTypeName = rName.getToken( 0, '.', nFound ); + sal_Int32 nIdx = 0; + rTypeName = rName.getToken( 0, '.', nIdx ); if (rTypeName == "User") nResId = SwFieldIds::User; else if (rTypeName == "DDE") @@ -2670,7 +2670,7 @@ static SwFieldIds lcl_GetIdByName( OUString& rName, OUString& rTypeName ) { nResId = SwFieldIds::SetExp; - const OUString sFieldTypName( rName.getToken( 1, '.' )); + const OUString sFieldTypName( rName.getToken( 0, '.', nIdx )); const OUString sUIName( SwStyleNameMapper::GetSpecialExtraUIName( sFieldTypName ) ); if( sUIName != sFieldTypName ) _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits