1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-03 07:05:24 +02:00

[199854] Regression in FTPService deletes files after upload

This commit is contained in:
Martin Oberhuber 2008-05-07 15:04:01 +00:00
parent c975488bf6
commit 7b40bac1eb

View file

@ -844,10 +844,9 @@ public class FTPService extends AbstractFileService implements IFTPService, IFil
InputStream input = null;
OutputStream output = null;
FTPClient ftpClient = getFTPClient();
try{
FTPClient ftpClient = getFTPClient();
clearCache(remoteParent);
ftpClient.changeWorkingDirectory(remoteParent);
setFileType(isBinary);
@ -875,8 +874,9 @@ public class FTPService extends AbstractFileService implements IFTPService, IFil
} else {
throw new RemoteFileIOException(new Exception(ftpClient.getReplyString()));
}
} catch (SystemOperationCancelledException e) {
ftpClient.deleteFile(remoteFile);
throw e;
}finally{
try {
if (input!=null) input.close();