435338 - Incorrect handling of asynchronous content.
Return values from parser and parser callbacks must not be ignored.
This commit is contained in:
parent
f225af318b
commit
7745e8b6c1
|
@ -98,7 +98,7 @@ public class ResponseContentParser extends StreamContentParser
|
||||||
{
|
{
|
||||||
case HEADERS:
|
case HEADERS:
|
||||||
{
|
{
|
||||||
if (httpParser.parseHeaders(buffer))
|
if (httpParser.parseNext(buffer))
|
||||||
state = State.CONTENT_MODE;
|
state = State.CONTENT_MODE;
|
||||||
remaining = buffer.remaining();
|
remaining = buffer.remaining();
|
||||||
break;
|
break;
|
||||||
|
@ -124,7 +124,8 @@ public class ResponseContentParser extends StreamContentParser
|
||||||
}
|
}
|
||||||
case HTTP_CONTENT:
|
case HTTP_CONTENT:
|
||||||
{
|
{
|
||||||
httpParser.parseContent(buffer);
|
if (httpParser.parseNext(buffer))
|
||||||
|
return true;
|
||||||
remaining = buffer.remaining();
|
remaining = buffer.remaining();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -250,8 +251,7 @@ public class ResponseContentParser extends StreamContentParser
|
||||||
@Override
|
@Override
|
||||||
public boolean content(ByteBuffer buffer)
|
public boolean content(ByteBuffer buffer)
|
||||||
{
|
{
|
||||||
notifyContent(buffer);
|
return notifyContent(buffer);
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean notifyContent(ByteBuffer buffer)
|
private boolean notifyContent(ByteBuffer buffer)
|
||||||
|
@ -305,18 +305,6 @@ public class ResponseContentParser extends StreamContentParser
|
||||||
setState(State.HEADER);
|
setState(State.HEADER);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
protected boolean parseHeaders(ByteBuffer buffer)
|
|
||||||
{
|
|
||||||
return super.parseHeaders(buffer);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
protected boolean parseContent(ByteBuffer buffer)
|
|
||||||
{
|
|
||||||
return super.parseContent(buffer);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void setResponseStatus(int status)
|
protected void setResponseStatus(int status)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue