mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-15 20:12:04 +01:00
Assert that processPacket is not called with null
This commit is contained in:
parent
d295939285
commit
5d5e3c05c5
2 changed files with 1 additions and 4 deletions
|
@ -905,6 +905,7 @@ public abstract class AbstractXMPPConnection implements XMPPConnection {
|
|||
* @param packet the packet to process.
|
||||
*/
|
||||
protected void processPacket(Packet packet) {
|
||||
assert(packet != null);
|
||||
lastStanzaReceived = System.currentTimeMillis();
|
||||
// Deliver the incoming packet to listeners.
|
||||
executorService.submit(new ListenerNotification(packet));
|
||||
|
|
|
@ -225,10 +225,6 @@ public class PacketCollector {
|
|||
* @param packet the packet to process.
|
||||
*/
|
||||
protected void processPacket(Packet packet) {
|
||||
if (packet == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (packetFilter == null || packetFilter.accept(packet)) {
|
||||
while (!resultQueue.offer(packet)) {
|
||||
// Since we know the queue is full, this poll should never actually block.
|
||||
|
|
Loading…
Reference in a new issue