Re: [PATCH] [v2] scsi: scsi_debug: Fix memleak in scsi_debug_init

2021-01-07 Thread Martin K. Petersen
On Sat, 26 Dec 2020 14:15:03 +0800, Dinghao Liu wrote: > When sdeb_zbc_model does not match BLK_ZONED_NONE, > BLK_ZONED_HA or BLK_ZONED_HM, we should free sdebug_q_arr > to prevent memleak. Also there is no need to execute > sdebug_erase_store() on failure of sdeb_zbc_model_str(). Applied to

Re: [PATCH] [v2] scsi: scsi_debug: Fix memleak in scsi_debug_init

2020-12-26 Thread Douglas Gilbert
On 2020-12-26 1:15 a.m., Dinghao Liu wrote: When sdeb_zbc_model does not match BLK_ZONED_NONE, BLK_ZONED_HA or BLK_ZONED_HM, we should free sdebug_q_arr to prevent memleak. Also there is no need to execute sdebug_erase_store() on failure of sdeb_zbc_model_str(). Signed-off-by: Dinghao Liu

[PATCH] [v2] scsi: scsi_debug: Fix memleak in scsi_debug_init

2020-12-25 Thread Dinghao Liu
When sdeb_zbc_model does not match BLK_ZONED_NONE, BLK_ZONED_HA or BLK_ZONED_HM, we should free sdebug_q_arr to prevent memleak. Also there is no need to execute sdebug_erase_store() on failure of sdeb_zbc_model_str(). Signed-off-by: Dinghao Liu --- Changelog: v2: - Add missed assignment