[SNMP4J] NPE in pduHandleAssigned

pierre.rust at orange.com pierre.rust at orange.com
Fri Oct 11 15:10:20 CEST 2013


Hi Franck,

Thank you very much for your answer, I will implement this workaround and upgrade to 2.2.3 as soon as it is available.

Regards,

Pierre Rust


> -----Message d'origine-----
> De : snmp4j-bounces at agentpp.org [mailto:snmp4j-bounces at agentpp.org] De la
> part de Frank Fock
> Envoyé : vendredi 11 octobre 2013 12:50
> À : snmp4j at agentpp.org
> Objet : Re: [SNMP4J] NPE in pduHandleAssigned
> 
> Hi Pierre,
> 
> You can avoid this exception if you cancel all pending requests before
> you close
> the Snmp session.
> 
> I agree, that the Snmp.close() should do this for you. I will provide a fix
> for it in version 2.2.3.
> 
> Best regards,
> Frank
> 
> Am 11.10.2013 10:45, schrieb pierre.rust at orange.com:
> > Hi,
> >
> > I'm using SNMP4J and I'm sometime getting an NPE in pduHandleAssigned :
> >
> > java.lang.NullPointerException
> > at org.snmp4j.Snmp$PendingRequest.pduHandleAssigned(Snmp.java:1624)
> > at org.snmp4j.Snmp$PendingRequest.pduHandleAssigned(Snmp.java:1485)
> > at
> org.snmp4j.MessageDispatcherImpl.sendPdu(MessageDispatcherImpl.java:495)
> > at org.snmp4j.Snmp.sendMessage(Snmp.java:1005)
> > at org.snmp4j.Snmp$PendingRequest.run(Snmp.java:1666)
> > at java.util.Timer$TimerImpl.run(Timer.java:284)
> >
> > Given that the line 1624 is :  "timer.schedule(this, delay);" , I assume
> the timer is null.
> >
> > It might be that this happens when closing SNMP4J with an ongoing
> PendingRequest  (in close(),  line 509, timer is set to null) but I'm
> unfortunately not able to confirm this assumption : the problem only
> happens "on the field" and I never reproduce it in debug.
> >
> > In can upgrade to 2.2.2, but I don't see any relevant difference in the
> (potentially offending) code.
> >
> > Do you have any idea of what I could do investigate this issue ?
> >
> >
> > thanks a lot for the good work,
> >
> > Pierre Rust
> >
> >
> >
> >
> >
> ___________________________________________________________________________
> ______________________________________________
> >
> > Ce message et ses pieces jointes peuvent contenir des informations
> confidentielles ou privilegiees et ne doivent donc
> > pas etre diffuses, exploites ou copies sans autorisation. Si vous avez
> recu ce message par erreur, veuillez le signaler
> > a l'expediteur et le detruire ainsi que les pieces jointes. Les messages
> electroniques etant susceptibles d'alteration,
> > Orange decline toute responsabilite si ce message a ete altere, deforme
> ou falsifie. Merci.
> >
> > This message and its attachments may contain confidential or privileged
> information that may be protected by law;
> > they should not be distributed, used or copied without authorisation.
> > If you have received this email in error, please notify the sender and
> delete this message and its attachments.
> > As emails may be altered, Orange is not liable for messages that have
> been modified, changed or falsified.
> > Thank you.
> >
> > _______________________________________________
> > 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
> 
> _______________________________________________
> SNMP4J mailing list
> SNMP4J at agentpp.org
> http://lists.agentpp.org/mailman/listinfo/snmp4j

_________________________________________________________________________________________________________________________

Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc
pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler
a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,
Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.

This message and its attachments may contain confidential or privileged information that may be protected by law;
they should not be distributed, used or copied without authorisation.
If you have received this email in error, please notify the sender and delete this message and its attachments.
As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.
Thank you.




More information about the SNMP4J mailing list