qc_free_ncbuf() may now be used with a NCBUF_NULL buffer as parameter.
This is useful when using this function on a QCS with no allocated
buffer. This case was not reproduced for the moment, but it will soon
become more present as buffers will be released if emptied.
Also a call to offer_buffers() is added to conform with the dynamic
buffer management of haproxy.
{
struct buffer buf;
+ if (ncb_is_null(ncbuf))
+ return;
+
buf = b_make(ncbuf->area, ncbuf->size, 0, 0);
b_free(&buf);
+ offer_buffers(NULL, 1);
*ncbuf = NCBUF_NULL;
}