[SNMP4J] Bug report: DefaultUdpTransportMapping not Closeable

Frank Fock fock at agentpp.com
Thu Jun 7 13:51:19 CEST 2012


Hi,

If the socket is already closed, then why should another close should 
run without
error?

Best regards,
Frank

Am 07.06.2012 11:42, schrieb wonder365:
> Hi,
>
>      I found if the DefaultUdpTransportMapping.socket closed abnormality, then TransportMapping can not close. I checked the code of org.snmp4j.transport.DefaultUdpTransportMapping.ListenThread.run() , and found setSocketTimeout will throw exception, and the DefaultUdpTransportMapping.isListening will always be true.
>
>        try {
>          socket.setSoTimeout(getSocketTimeout());
>          ........
>        }
>        catch (SocketException ex) {
>          logger.error(ex);
>          setSocketTimeout(0); //!!! this line will throw runtimeexecption if socket.isclosed .
>        }
>
>      somebody help me and explains this?
> _______________________________________________
> SNMP4J mailing list
> SNMP4J at agentpp.org
> http://lists.agentpp.org/mailman/listinfo/snmp4j

-- 
---
AGENT++
Maximilian-Kolbe-Str. 10
73257 Koengen, Germany
https://agentpp.com
Phone: +49 7024 8688230
Fax:   +49 7024 8688231




More information about the SNMP4J mailing list