1
Vote

remoteFile not closed if error on localFile

description

Hello,

in both of your copy function : CopyFileFromDevice and CopyFileToDevice, there is no check if new FileStream works for localFile. So if it an exception is dispatch from it, remoteFile is not closed and we can't delete the remote file.
I had this error when I test CopyFileFromDevice without overwrite (the file exist on PC) and I wanted to delete remote file after that.

comments