summaryrefslogtreecommitdiff
path: root/lib/snmp
diff options
context:
space:
mode:
authorMicael Karlberg <bmk@erlang.org>2021-09-20 18:31:47 +0200
committerMicael Karlberg <bmk@erlang.org>2021-09-27 15:16:51 +0200
commit09cc84fe973aa9a89f084b5d9c89460ceb565f30 (patch)
tree8f150801cb16a546fa355b07d0ce41d287757b69 /lib/snmp
parent1b0a9a039a1d078c8e4f25f3eaa765259b256ace (diff)
downloaderlang-09cc84fe973aa9a89f084b5d9c89460ceb565f30.tar.gz
[snmp|agent] Handling of socket (monitor) DOWN message
The net-if process incorrectly expected the 'type' of the DOWN message to be 'socket'. But the old style sockets is of type 'port'. OTP-17641
Diffstat (limited to 'lib/snmp')
-rw-r--r--lib/snmp/src/agent/snmpa_net_if.erl3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/snmp/src/agent/snmpa_net_if.erl b/lib/snmp/src/agent/snmpa_net_if.erl
index cdb68afef4..c0ab7c9f8d 100644
--- a/lib/snmp/src/agent/snmpa_net_if.erl
+++ b/lib/snmp/src/agent/snmpa_net_if.erl
@@ -768,7 +768,8 @@ loop(#state{transports = Transports,
"~n ~p", [Parent, Reason]),
exit(Reason);
- {'DOWN', _SockMRef, socket, Socket, Reason} ->
+ {'DOWN', _SockMRef, Type, Socket, Reason} when (Type =:= port) orelse
+ (Type =:= socket) ->
case lists:keyfind(Socket, #transport.socket, Transports) of
#transport{
socket = Socket,