Re: StringNG merge?

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Tue, 18 Dec 2012 11:42:48 +1300

On 18.12.2012 07:39, Kinkie wrote:
> On Tue, Nov 13, 2012 at 12:50 AM, Alex Rousskov wrote:
>> On 11/12/2012 03:40 PM, Amos Jeffries wrote:
>>> On 13.11.2012 09:21, Alex Rousskov wrote:
>>>> On 11/03/2012 05:55 AM, Kinkie wrote:
>>>>
>>>>> Feature-branch is at lp:~kinkie/squid/stringng
>>>>
>>>>

<snip>

>>> 2) one of the goals of SBuf rollout is to erase xstrdup() and its
>>> null-terminated requirement from Squid.
>>
>> In this particular case, xmalloc() followed by manual
>> null-termination
>> is even worse than a simple xstrdup()!
>
> If only xstrdup could take an optional length parameter...
> Would you agree to extending it (or defining an xstrndup which does)
> ?

I have no problem with that if done carefully to validate all input
case permutations cleanly.

Amos
Received on Mon Dec 17 2012 - 22:42:52 MST

This archive was generated by hypermail 2.2.0 : Tue Dec 18 2012 - 12:00:19 MST