mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-15 04:55:22 +02:00
[199854] Regression in FTPService deletes files after upload
This commit is contained in:
parent
c975488bf6
commit
7b40bac1eb
1 changed files with 3 additions and 3 deletions
|
@ -844,10 +844,9 @@ public class FTPService extends AbstractFileService implements IFTPService, IFil
|
||||||
|
|
||||||
InputStream input = null;
|
InputStream input = null;
|
||||||
OutputStream output = null;
|
OutputStream output = null;
|
||||||
|
FTPClient ftpClient = getFTPClient();
|
||||||
|
|
||||||
try{
|
try{
|
||||||
|
|
||||||
FTPClient ftpClient = getFTPClient();
|
|
||||||
clearCache(remoteParent);
|
clearCache(remoteParent);
|
||||||
ftpClient.changeWorkingDirectory(remoteParent);
|
ftpClient.changeWorkingDirectory(remoteParent);
|
||||||
setFileType(isBinary);
|
setFileType(isBinary);
|
||||||
|
@ -875,8 +874,9 @@ public class FTPService extends AbstractFileService implements IFTPService, IFil
|
||||||
} else {
|
} else {
|
||||||
throw new RemoteFileIOException(new Exception(ftpClient.getReplyString()));
|
throw new RemoteFileIOException(new Exception(ftpClient.getReplyString()));
|
||||||
}
|
}
|
||||||
|
} catch (SystemOperationCancelledException e) {
|
||||||
ftpClient.deleteFile(remoteFile);
|
ftpClient.deleteFile(remoteFile);
|
||||||
|
throw e;
|
||||||
}finally{
|
}finally{
|
||||||
try {
|
try {
|
||||||
if (input!=null) input.close();
|
if (input!=null) input.close();
|
||||||
|
|
Loading…
Add table
Reference in a new issue