ARSoft.Tools.Net icon indicating copy to clipboard operation
ARSoft.Tools.Net copied to clipboard

Exception handling missing details

Open henning-krause opened this issue 5 months ago • 0 comments

There are 3 places in the library where I find this code:

if ((msg == null) || ((msg.ReturnCode != ReturnCode.NoError) && (msg.ReturnCode != ReturnCode.NxDomain)))
{
	throw new Exception("DNS request failed");
}

The exception does not include the actual error code returned from the DNS server (if a message was received).

I'd like to contribute a change here. @alexreinert, do you accept PRs for this?

henning-krause avatar Jan 22 '24 14:01 henning-krause