>>> As I mentioned in a separate email, this operation allocates memory
>>> for our input parameters. I want to avoid altering their values, then
>>> destroying the memory holding their new values. While I don't believe
>>> that those values are used now, this is a safe practice which leaves
>>> the code without booby-traps (and thus easier to modify).
>>>
>>> - Dan
>>>
>>>
>> Given the call it can only modify '&pair->src_kind' as 'pair->src_kind'
>> is an enum it does not need any allocation, so no need to worry abt pool
>> destruction.
>>
>
> I think Kamesh is right on this one. The use of the pool parameter
> isn't documented in svn_io.h, and looking at the internals, pool is only
> used for allocations inside svn_io_check_path, not for anything that
> gets returned. pair->src_kind isn't allocated, just set to an enum value.
>
> Using iterpool here is safe.
>
> -Hyrum
>
>
Yes we do so the same 9 lines downwards
SVN_ERR(svn_io_check_path(pair->dst, &dst_kind, iterpool));
With regards
Kamesh Jayachandran
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Dec 20 16:17:28 2006