<div dir="ltr">Thank you, Stuart.<div><br></div><div>I do have a related question: should a 304 response set a Content-Length: 0? Don't think so, right?</div><div><br></div><div>Today, Undertow set a content-length of 0 on 304 responses.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Feb 16, 2015 at 12:29 AM, Stuart Douglas <span dir="ltr"><<a href="mailto:sdouglas@redhat.com" target="_blank">sdouglas@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">This is indeed a bug, however it should have been fixed as part of <a href="https://issues.jboss.org/browse/UNDERTOW-180" target="_blank">https://issues.jboss.org/browse/UNDERTOW-180</a>.<br>
<br>
Looking at the code it appears that AsyncSenderImpl also has this issue, I will fix it up (<a href="https://issues.jboss.org/browse/UNDERTOW-385" target="_blank">https://issues.jboss.org/browse/UNDERTOW-385</a>).<br>
<br>
Stuart<br>
<div><div class="h5"><br>
----- Original Message -----<br>
> From: "Edgar Espina" <<a href="mailto:espina.edgar@gmail.com">espina.edgar@gmail.com</a>><br>
> To: <a href="mailto:undertow-dev@lists.jboss.org">undertow-dev@lists.jboss.org</a><br>
> Sent: Tuesday, 10 February, 2015 10:36:20 PM<br>
> Subject: [undertow-dev] transfer-encoding vs content-length with small response<br>
><br>
> Hi,<br>
><br>
> I know that Undertow figure it out a content-length or transfer-encoding<br>
> header when none of them was set. That's good and it works as expected.<br>
><br>
> It seems to be a problem when you explicitly set the "Transfer-Encoding"<br>
> header bc Undertow, still add the Content-Length (on small responses?) but<br>
> it doesn't remove the Transfer-Encoding header.<br>
><br>
> On such cases, the response contains both headers, which I think it's wrong,<br>
> no?<br>
><br>
> --<br>
> edgar<br>
><br>
</div></div>> _______________________________________________<br>
> undertow-dev mailing list<br>
> <a href="mailto:undertow-dev@lists.jboss.org">undertow-dev@lists.jboss.org</a><br>
> <a href="https://lists.jboss.org/mailman/listinfo/undertow-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/undertow-dev</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">edgar</div>
</div>