Re: [PATCH] block: Fix uninitialized symbol 'bio' in blk_rq_prep_clone
From: Christoph Hellwig
Date: Fri Oct 04 2024 - 08:22:55 EST
On Fri, Oct 04, 2024 at 03:38:42PM +0530, SurajSonawane2415 wrote:
> Fix the uninitialized symbol 'bio' in the function blk_rq_prep_clone
> to resolve the following error:
> block/blk-mq.c:3199 blk_rq_prep_clone() error: uninitialized symbol 'bio'.
>
> Initialize 'bio' to NULL to prevent undefined behavior from uninitialized
> access and safe cleanup in case of failure.
Please explain how bio could be used uninitialized in this function.