mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-03 15:15:25 +02:00
avoid NPE on non-VMS servers containing DOS-like paths as root (as WFTPD)
This commit is contained in:
parent
cf475049f2
commit
a289426950
1 changed files with 1 additions and 1 deletions
|
@ -360,7 +360,7 @@ public class FTPService extends AbstractFileService implements IFileService, IFT
|
|||
_userHome = _ftpClient.printWorkingDirectory();
|
||||
|
||||
//For VMS, normalize the home location
|
||||
if(_userHome.indexOf(':')!=-1)
|
||||
if(_userHome.indexOf(':')!=-1 && _userHome.indexOf(']')!=-1)
|
||||
{
|
||||
_userHome = _userHome.replaceAll(":\\[", "/"); //$NON-NLS-1$ //$NON-NLS-2$
|
||||
_userHome = '/'+_userHome.substring(0,_userHome.lastIndexOf(']'));
|
||||
|
|
Loading…
Add table
Reference in a new issue