[squid-dev] [PATCH] Bug3329

Alex Rousskov rousskov at measurement-factory.com
Fri May 29 19:18:37 UTC 2015


On 05/25/2015 05:37 AM, Amos Jeffries wrote:
> On 25/05/2015 10:13 p.m., Tsantilas Christos wrote:
>>   I am attaching new squid patches for bug3329.


> +1 on the conversion of comm_close() to X->close()

> However please name the noteClsure() as noteClosureXXX() to highlight
> that this function is undesirable and we need to fix the underlying
> problem still for the places which find themselves having to use it.


Hi Amos,

    Adding XXX to function names is only useful when an XXX marks a
problem in the callers code. In this case, the problem is not in the
caller at all! There is no point in bringing readers attention to the
surrounding call code. Moreover, we should enforce noteClosure() usage
in relevant callbacks, not discourage it!

Is there a bigger problem here? Yes, as the proposed commit message
documents. However, adding an XXX to this method name will not help us
avoid that bigger problem or solve it.

If you insist on naming the new method noteClosureXXX(), I am not going
to spend more cycles arguing against it, but if you are OK with the
proposed noteClosure() going in, let's commit "as is".


HTH,

Alex.



More information about the squid-dev mailing list