aboutsummaryrefslogtreecommitdiffstats
path: root/lib/snmp/src/agent/snmpa_mpd.erl
diff options
context:
space:
mode:
authorMicael Karlberg <[email protected]>2011-07-13 11:00:26 +0200
committerMicael Karlberg <[email protected]>2011-07-13 11:00:26 +0200
commit989fca957acc84d71c67bfe7646f665cca00bac0 (patch)
tree2350607deeadf431bbba0d6c516b934ae8cdd834 /lib/snmp/src/agent/snmpa_mpd.erl
parent5bccd012d163a98dd59191db9f69134ccef49faf (diff)
downloadotp-989fca957acc84d71c67bfe7646f665cca00bac0.tar.gz
otp-989fca957acc84d71c67bfe7646f665cca00bac0.tar.bz2
otp-989fca957acc84d71c67bfe7646f665cca00bac0.zip
Improved (transport) domain error reporting.
Diffstat (limited to 'lib/snmp/src/agent/snmpa_mpd.erl')
-rw-r--r--lib/snmp/src/agent/snmpa_mpd.erl9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/snmp/src/agent/snmpa_mpd.erl b/lib/snmp/src/agent/snmpa_mpd.erl
index 21c333b950..4f50b1a674 100644
--- a/lib/snmp/src/agent/snmpa_mpd.erl
+++ b/lib/snmp/src/agent/snmpa_mpd.erl
@@ -1080,8 +1080,13 @@ transform_taddr(?transportDomainUdpIpv6,
{ok, {Domain, Address}};
transform_taddr(?transportDomainUdpIpv6, BadAddr) ->
{error, {bad_transportDomainUdpIpv6_address, BadAddr}};
-transform_taddr(BadTDomain, BadTAddress) ->
- {error, {bad_domain, BadTDomain, BadTAddress}}.
+transform_taddr(BadTDomain, TAddress) ->
+ case lists:member(BadTDomain, snmp_conf:all_tdomains()) of
+ true ->
+ {error, {unsupported_tdomain, BadTDomain, TAddress}};
+ false ->
+ {error, {unknown_tdomain, BadTDomain, TAddress}}
+ end.
process_taddrs(Dests) ->