gluster-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gluster-devel] [PATCH 2/2] features/locks: Fix insert_and_merge


From: Corentin Chary
Subject: Re: [Gluster-devel] [PATCH 2/2] features/locks: Fix insert_and_merge
Date: Fri, 9 Oct 2009 14:21:10 +0200

On Fri, Oct 9, 2009 at 1:06 PM, Anand Avati <address@hidden> wrote:
> Corentin,
>  This is a good catch! Thank you for the patch. It will be included
> in our next RC release. I will be reformatting this patch slightly
> however. The BUG: and URL: lines will be automatically added in our
> commit scripts if you just generate the patch from ./format-patch.sh,
> but we'll do the reformatting.
>
> Thanks once again!
> Avati
>

I just checked the modified patch: INIT_LIST_HEAD *is* necessary.
subtract_locks() do a memcpy of the lock, so it copy list pointers,
but the new lock *is not* in the list.
So INIT_LIST_HEAD() must be called to initialize the list structure.
Else, this will just segfault (At least it did with my testcase).
Thanks,
-- 
Corentin Chary
http://xf.iksaif.net




reply via email to

[Prev in Thread] Current Thread [Next in Thread]