Fixes #4082 - Debug logging causes NullPointerException in client.
Using BufferUtil to guard against NPEs. Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
This commit is contained in:
parent
43e10f8a5e
commit
8c1e0b0714
|
@ -173,10 +173,10 @@ public class HttpReceiverOverHTTP extends HttpReceiver implements HttpParser.Res
|
|||
boolean complete = this.complete;
|
||||
this.complete = false;
|
||||
if (LOG.isDebugEnabled())
|
||||
LOG.debug("Parsed {}, remaining {} {}", handle, buffer.remaining(), parser);
|
||||
LOG.debug("Parsed {}, remaining {} {}", handle, BufferUtil.length(buffer), parser);
|
||||
if (handle)
|
||||
return true;
|
||||
if (!buffer.hasRemaining())
|
||||
if (!BufferUtil.hasContent(buffer))
|
||||
return false;
|
||||
if (complete)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue