Projects tigase _server tigase-muc Issues #128
NPE in VCardModule (#128)
wojciech.kapcia@tigase.net opened 5 years ago
[2020-01-26 05:40:56:414] [FINEST  ] [              in_2-muc ] MessageRouter.processPacket()    : Processing packet: from=test2@muc.tigase.org, to=s2s@ip-10-0-25-37.us-west-2.compute.internal, DATA=[iq to="neustradamus@jabber.org/client" xmlns="jabber:client" id="ab63a" type="result" from="test2@muc.tigase.org"][query xmlns="http://jabber.org/protocol/disco#info"][identity name="" category="conference" type="text"/][feature var="http://jabber.org/protocol/muc"/][feature var="vcard-temp"/][feature var="jabber:iq:register"/][feature var="muc_semianonymous"/][feature var="muc_unmoderated"/][feature var="muc_open"/][feature var="muc_persistent"/][feature var="muc_hidden"/][feature var="muc_unsecured"/][feature var="urn:xmpp:mam:1"/][x xmlns="jabber:x:data" type="result"][field var="FORM_TYPE" type="hidden"][value]http://jabber.org/protocol/muc#roominfo[/value][/field][field var="muc#roominfo_creationdate" label="Room creation date"][value]2020-01-25T14:35:26Z[/value][/field][field var="muc#roominfo_occupants" label="Number of occupants"][value]1[/value][/field][field var="muc#roominfo_subject" label="Current discussion topic"][value/][/field][field var="muc#roomconfig_allowinvites" label="Whether occupants  ... , SIZE=2740, XMLNS=jabber:client, PRIORITY=NORMAL, PERMISSION=NONE, TYPE=result
[2020-01-26 05:40:56:414] [FINEST  ] [              in_2-muc ] MessageRouter.getLocalComponent(): Called for : neustradamus@jabber.org/client
[2020-01-26 05:40:56:414] [SEVERE  ] [              in_2-muc ] StanzaProcessor.processPacket()  : java.lang.NullPointerException when processing from=s2s@ip-10-0-25-37.us-west-2.compute.internal, to=null, DATA=[iq to="test2@muc.tigase.org" from="neustradamus@jabber.org/client" id="ab64a" type="get" xmlns="jabber:client"][vCard xmlns="vcard-temp"/][/iq], SIZE=144, XMLNS=jabber:client, PRIORITY=NORMAL, PERMISSION=REMOTE, TYPE=get
java.lang.RuntimeException: java.lang.NullPointerException
	at tigase.muc.modules.VCardModule.process(VCardModule.java:138)
	at tigase.component.modules.StanzaProcessor.process(StanzaProcessor.java:164)
	at tigase.component.modules.StanzaProcessor.processPacket(StanzaProcessor.java:85)
	at tigase.component.AbstractKernelBasedComponent.processPacket(AbstractKernelBasedComponent.java:81)
	at tigase.muc.MUCComponent.processPacket(MUCComponent.java:122)
	at tigase.muc.cluster.MUCComponentClustered.processPacket(SourceFile:87)
	at tigase.server.AbstractMessageReceiver$QueueListener.run(AbstractMessageReceiver.java:1401)
Caused by: java.lang.NullPointerException
	at tigase.muc.repository.JDBCMucDAO.getRoomAvatar(JDBCMucDAO.java:250)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:567)
	at tigase.stats.StatisticsInvocationHandler.invoke(StatisticsInvocationHandler.java:75)
	at com.sun.proxy.$Proxy51.getRoomAvatar(Unknown Source)
	at tigase.muc.repository.MucDAOMDBean.getRoomAvatar(MucDAOMDBean.java:111)
	at tigase.muc.repository.inmemory.InMemoryMucRepository.getRoomAvatar(InMemoryMucRepository.java:128)
	at tigase.muc.modules.VCardModule.processGet(VCardModule.java:174)
	at tigase.muc.modules.VCardModule.process(VCardModule.java:129)
Andrzej Wójcik (Tigase) commented 5 years ago

Fixed by adding check if rooom id is not null before using it.

Referenced from commit 1 year ago
issue 1 of 1
Type
Bug
Priority
Normal
Assignee
Version
tigase-server-8.1.0
Issue Votes (0)
Watchers (0)
Reference
tigase/_server/tigase-muc#128
Please wait...
Page is in error, reload to recover