Re: [PATCH v3 01/38] zbd: return ENOMEM if zone buffer allocation fails

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

 



On Jan 07, 2021 / 06:57, Dmitry Fomichev wrote:
> parse_zone_info() function tries to allocate a buffer of
> ZBD_REPORT_MAX_ZONES zone descriptors and exits if this allocation
> fails. The problem is that it returns 0 error code in this case and
> the caller may interpret this as the success.
> 
> Just return ENOMEM if we can't allocate that buffer.
> 
> Signed-off-by: Dmitry Fomichev <dmitry.fomichev@xxxxxxx>

Looks good to me.

Reviewed-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@xxxxxxx>

-- 
Best Regards,
Shin'ichiro Kawasaki



[Index of Archives]     [Linux Kernel]     [Linux SCSI]     [Linux IDE]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux