From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Date: Wed, 30 Mar 2022 08:56:41 -0700 Subject: [Cluster-devel] [PATCH] gfs2: Add check for mempool_alloc In-Reply-To: <20220311083616.2213689-1-jiasheng@iscas.ac.cn> References: <20220311083616.2213689-1-jiasheng@iscas.ac.cn> Message-ID: List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Fri, Mar 11, 2022 at 04:36:16PM +0800, Jiasheng Jiang wrote: > As the potential failure of mempool_alloc(), > it could return NULL pointer. > Therefore, it should be better to check it > in order to avoid the dereference of the NULL > pointer. > > Fixes: e8c92ed76900 ("GFS2: Clean up log write code path") > Signed-off-by: Jiasheng Jiang Please explain how it could fail to start with.