sshnet / SSH.NET

SSH.NET is a Secure Shell (SSH) library for .NET, optimized for parallelism.
http://sshnet.github.io/SSH.NET/
MIT License
3.88k stars 919 forks source link

Remove unneeded feature flags and pass cancellationToken to DNS request #1290

Closed mus65 closed 5 months ago

mus65 commented 5 months ago

This removes feature flags that were unused. FEATURE_SOCKET_EAP and FEATURE_DNS_SYNC were set for all frameworks, so unneeded. The other feature flags were only used in elif of FEATURE_SOCKET_EAP and FEATURE_DNS_SYNC, so also unneeded.

After removing these, DnsAbstractions.cs seemed to be an unneeded abstraction at first, but then I noticed that .NET 6+ supports a cancellationToken on GetHostAddressesAsync, so I kept DnsAbstractions.cs to pass this through (I could do a separate PR for this if you want).

WojciechNagorski commented 4 months ago

This issue has been fixed in the 2024.0.0 version.