Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

return earlier when there is no record

  • Loading branch information...
commit 7dac59246b706076cd1d39d4f4a43fcc0cca2c01 1 parent 4a6fe2d
@gdusbabek gdusbabek authored
Showing with 4 additions and 3 deletions.
  1. +4 −3 src/com/rackspace/flewton/CollectorHandler.java
View
7 src/com/rackspace/flewton/CollectorHandler.java
@@ -73,6 +73,7 @@ public void messageReceived(ChannelHandlerContext ctx, MessageEvent e) {
logger.warn(String.format("Netflow v%d is not supported", version));
if (logger.isDebugEnabled())
logPacket(e.getRemoteAddress(), buff.duplicate());
+ return;
} else
throw new UnsupportedOperationException(
String.format("Netflow v%d is not supported", version));
@@ -83,9 +84,9 @@ public void messageReceived(ChannelHandlerContext ctx, MessageEvent e) {
}
// Send record to backends
- if (record != null)
- for (IBackend backend : backEnds)
- backend.write(record);
+ assert record != null;
+ for (IBackend backend : backEnds)
+ backend.write(record);
}
// dumps the contents of a buffer
Please sign in to comment.
Something went wrong with that request. Please try again.