Welcome! Log In Create A New Profile

Advanced

Re: Does zero buffer allowed in the output buffer chain?

Maxim Dounin
January 30, 2013 02:14PM
Hello!

On Wed, Jan 30, 2013 at 11:03:15AM +0800, Liu Haifeng wrote:

> I am writing a http handler module, I found when the last buffer
> in the output buffer chain is zero, I'll get an alert in the
> error log about zero output buffer, and the browser will get no
> response after waiting a while, this is not what I am expecting
> as the buffer chain has data, just the last one has zero size.
> Does this a feature or I missed something else?

Zero size buffers are not expected to appear in the output chain
except due to some bug, and if they do appear - it's considered to
be a fatal error and results in a connection close.

Normally you should not add empty buffers to the output chain. If
there are some good reasons why you need to add an empty buffer -
you have to mark the buffer as special, e.g., by setting the
b->sync flag as Jeff Kaufman already suggested.

--
Maxim Dounin
http://nginx.com/support.html

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Does zero buffer allowed in the output buffer chain?

Liu Haifeng January 30, 2013 12:00AM

Re: Does zero buffer allowed in the output buffer chain?

Jeff Kaufman January 30, 2013 01:32PM

Re: Does zero buffer allowed in the output buffer chain?

Maxim Dounin January 30, 2013 02:14PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 170
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready