protected override void Dispose( bool disposing ) {
try {
if ( disposing && stream != null ) {
if ( downloadManager != null ) {
downloadManager.Remove( host );
}
stream.Close();
}
stream = null;
GC.SuppressFinalize( this ); // do not call finalizer
}
finally {
base.Dispose( disposing );
}
}