No you don't have to call Close
, since Dispose
already does that. FtpWebResponse
is inherited from WebResponse
and it has explicitly implemented Dispose
, which internally call Close
.
Code for WebResponse.cs
from : http://www.dotnetframework.org/default.aspx/4@0/4@0/DEVDIV_TFS/Dev10/Releases/RTMRel/ndp/fx/src/Net/System/Net/WebResponse@cs/1305376/WebResponse@cs
/// <internalonly>
void IDisposable.Dispose() {
try
{
Close();
OnDispose();
}
catch { }
}