powered by Jive Software

NPE in LocalMUCRoom.java

In OF v4.5.2 w/cluster enabled we’re getting an NPE as follows:

2021.02.27 15:18:56 org.jivesoftware.openfire.muc.spi.MultiUserChatServiceImpl - Internal server error
java.lang.NullPointerException: null
        at org.jivesoftware.openfire.muc.spi.LocalMUCRoom.joinRoom(LocalMUCRoom.java:676) ~[xmppserver-4.5.2.jar:4.5.2]
        at org.jivesoftware.openfire.muc.spi.LocalMUCUser.process(LocalMUCUser.java:485) ~[xmppserver-4.5.2.jar:4.5.2]
        at org.jivesoftware.openfire.muc.spi.LocalMUCUser.process(LocalMUCUser.java:180) ~[xmppserver-4.5.2.jar:4.5.2]

If the same method in LocalMUCRoom v4.6.2 is called with the same state/parameters, then the NPE will be thrown at https://github.com/igniterealtime/Openfire/blob/3acceb064aeb3e6a2b3306ec35ceebc1e3cc8c8f/xmppserver/src/main/java/org/jivesoftware/openfire/muc/spi/LocalMUCRoom.java#L676

NPE will still be thrown. There are other code paths in OF sourcecode that expect non-null values and throw NPEs instead of degrading gracefully.

Can the community report this in a bug-reporting system? Is there a writeup on unit testing and debugging Openfire sourcecode?