NullPointerException when user is banned
Posted: 08 May 2011, 16:51
SFS PRO Licence 100 users
I dont understand why I get the following error from the server when I use the antiflood system. It happens when the first user is banned, then the antiflood system is simply inactive(crashed?).
I dont understand why I get the following error from the server when I use the antiflood system. It happens when the first user is banned, then the antiflood system is simply inactive(crashed?).
config.xmljvm 1 | 17:26:08.345 - [ WARNING ] > User: hellouser (78.xxx.xxx.xxx) is being kicked. Reason: flooding.
jvm 1 | 17:26:08.345 - [ WARNING ] > Unexpected Exception: java.lang.NullPointerException
jvm 1 | java.lang.NullPointerException
jvm 1 | at it.gotoandplay.smartfoxserver.SmartFoxServer.addBannedUser(SmartFoxServer.java:2683)
jvm 1 | at it.gotoandplay.smartfoxserver.SmartFoxServer.addKickedUser(SmartFoxServer.java:2884)
jvm 1 | at it.gotoandplay.smartfoxserver.controllers.SystemHandler.applyFloodFilter(SystemHandler.java:3897)
jvm 1 | at it.gotoandplay.smartfoxserver.controllers.SystemHandler.handlePublicMessage(SystemHandler.java:1346)
jvm 1 | at it.gotoandplay.smartfoxserver.controllers.SystemHandler.processEvent(SystemHandler.java:263)
jvm 1 | at it.gotoandplay.smartfoxserver.controllers.SystemHandler.run(SystemHandler.java:168)
jvm 1 | at java.lang.Thread.run(Thread.java:619)
Code: Select all
<AntiFlood active="true">
<MinMsgTime tolerance="2">1500</MinMsgTime>
<MaxRepeatedMessages>2</MaxRepeatedMessages>
<WarningsBeforeKick>2</WarningsBeforeKick>
<WarningMessage><![CDATA[WARNING_FLOOD]]></WarningMessage>
<KickMessage><![CDATA[KICKED_FLOOD]]></KickMessage>
<BanMessage><![CDATA[BANNED_FLOOD]]></BanMessage>
<BanAfter timeSpan="60">2</BanAfter>
</AntiFlood>
<BadWordsFilter active="true">
<FilterMode>REMOVE</FilterMode> <!-- REMOVE or FILTER -->
<StripCharacters><![CDATA[,.;:_!$%&/#*-+]]></StripCharacters>
<Warnings>true</Warnings>
<FilterRoomNames>true</FilterRoomNames>
<FilterUserNames>false</FilterUserNames>
<WarningsBeforeKick>2</WarningsBeforeKick>
<WarningMessage><![CDATA[WARNING_SWEARING]]></WarningMessage>
<KickMessage><![CDATA[KICKED_SWEARING]]></KickMessage>
<BanMessage><![CDATA[BANNED_SWEARING]]></BanMessage>
<BanAfter timeSpan="60">2</BanAfter>
<BadWordsList>
<badWord>dickhead</badWord>
<badWord>asshole</badWord>
<badWord>shithead</badWord>
<badWord>shit</badWord>
<badWord>fucking</badWord>
<badWord>fuck</badWord>
</BadWordsList>
</BadWordsFilter>
<BanCleaning>auto</BanCleaning>
<BanDuration>1800</BanDuration> <!-- 30 min -->
<BannedLoginMessage>You have been banned!</BannedLoginMessage>