Suggested bugfix: FTP.GetFile() method - file remains open after exeception

Nov 30, 2012 at 9:35 AM

After the this line of code:

if (!((response.ID == StatusCode.FileStatusOK) || (response.ID == StatusCode.ConnectionAlreadyOpen)))

Put the following :

output.Close();

Without this line the output file remains open and there is no way for the calling program to close it which is needed for further processing (for example deleting it as it is incomplete)

Coordinator
Dec 1, 2012 at 5:43 PM

Thanks for the report.  I've fixed the source tree and checked it in.