[Ocfs2-devel] [PATCH v2] ocfs2: fix possible memory leak in dlm_process_recovery_data

2013-05-02 Thread Joseph Qi
We found a possible memory leak in dlm_process_recovery_data when doing code review. In dlm_process_recovery_data, it creates newlock each time, but don't free when it is bad, and then it will lead to memory leak. Cc: sta...@vger.kernel.org Signed-off-by: Joseph Qi joseph...@huawei.com

Re: [Ocfs2-devel] [PATCH v2] ocfs2: fix possible memory leak in dlm_process_recovery_data

2013-05-02 Thread Sunil Mushran
Do you know under what conditions does it create a new lock when it should not? This code should only trigger if the lockres is/was mastered on another node. Meaning this node will not know about the newlock. Meaning that code should never trigger. 1949 if (lock-ml.cookie