Should Sftp_Disconenct always be called? - WeOnlyDo Discussion board

Should Sftp_Disconenct always be called? (General questions)

by Mike Hufnagel, Wednesday, August 11, 2010, 21:13 (5216 days ago)

Should Sftp_Disconnect be called before Sftp_Destroy or would it be redundant?

I don't see anything in the doc about this - let me know if I missed something.

Thanks,

Mike

Re: Should Sftp_Disconenct always be called?

by wodDamir, Wednesday, August 11, 2010, 21:27 (5216 days ago) @ Mike Hufnagel

Hi Mike,

The Destroy will destroy the instance of the component, and free the memory it took. It should also disconnect the socket automatically.

Disconnect on the other hand will just close the socket connection, allowing you to re-use the same instance again.

Hope this helps.

Regards,
Damba

Re: Should Sftp_Disconenct always be called?

by Mike Hufnagel, Wednesday, August 11, 2010, 21:47 (5216 days ago) @ wodDamir

Thanks Damba