Re: comm_write(), write cancellations, etc

From: Adrian Chadd <adrian_at_squid-cache.org>
Date: Fri, 22 Aug 2008 23:49:57 +0800

2008/8/22 Adrian Chadd <adrian_at_squid-cache.org>:
> G'day again,

[snip]

> (Now, for those who are scared - _yes_, they stay stable in
> client_side.c[c] in all of Squid-2.6, 2.7 and 2.HEAD as far as I can
> tell (and thus they should be in 3.x) - not by API contract, but by
> sheer luck. ;)

Actually, for 2.6, 2.7 and 3.x it -should- be ok - the
copy-into-temporary-buffer-and-write trick should be relatively
consistent.

This -may- not hold for 2.HEAD as I'm taking a buffer reference and
passing a {const char *, int} from that to comm_write() and deref'ing
it when the object is destroyed. This may go south if there's a write
scheduled but not cancelled implicitly by a comm_close() when the
object free's its own cbdata pointer.

Gah, this will all make much more sense when proper reference-counted
buffers and buffer regions make an appearance. Soon..

Adrian
Received on Fri Aug 22 2008 - 15:50:01 MDT

This archive was generated by hypermail 2.2.0 : Fri Aug 22 2008 - 12:00:07 MDT