diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-05-16 12:36:14 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-05-17 10:14:21 +0200 |
commit | 195ea6ced2e3cb2ae32faec07e5737e1664739e6 (patch) | |
tree | e296ee06eeda2f61d942f753cbf52cd32374a8a5 /cui | |
parent | 61964fc19da92ad5ff988fc071a94da61434fb7d (diff) |
'/' appearing in java classpath list
regression from...
commit 2f6b3fb0f30cd03e5ac60805a922711bdcab77f9
Date: Wed Apr 25 18:21:46 2018 +0200
Avoid comphelper::string::getTokenCount()
Change-Id: I5bbfa38d8cceb56fe03282c89039ab30cf108204
Reviewed-on: https://gerrit.libreoffice.org/54422
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'cui')
-rw-r--r-- | cui/source/options/optjava.cxx | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/cui/source/options/optjava.cxx b/cui/source/options/optjava.cxx index 23a5a9f5f299..3f8c0cb794da 100644 --- a/cui/source/options/optjava.cxx +++ b/cui/source/options/optjava.cxx @@ -1001,15 +1001,18 @@ void SvxJavaClassPathDlg::SetClassPath( const OUString& _rPath ) if ( m_sOldPath.isEmpty() ) m_sOldPath = _rPath; m_xPathList->clear(); - sal_Int32 nIdx = 0; - do + if (!_rPath.isEmpty()) { - OUString sToken = _rPath.getToken( 0, CLASSPATH_DELIMITER, nIdx ); - INetURLObject aURL( sToken, FSysStyle::Detect ); - OUString sPath = aURL.getFSysPath( FSysStyle::Detect ); - m_xPathList->append("", sPath, SvFileInformationManager::GetImageId(aURL)); + sal_Int32 nIdx = 0; + do + { + OUString sToken = _rPath.getToken( 0, CLASSPATH_DELIMITER, nIdx ); + INetURLObject aURL( sToken, FSysStyle::Detect ); + OUString sPath = aURL.getFSysPath( FSysStyle::Detect ); + m_xPathList->append("", sPath, SvFileInformationManager::GetImageId(aURL)); + } + while (nIdx>=0); } - while (nIdx>=0); // select first entry m_xPathList->select(0); SelectHdl_Impl(*m_xPathList); |