diff options
| author | Ally Heev <allyheev@gmail.com> | 2025-11-05 19:44:43 +0530 |
|---|---|---|
| committer | Martin K. Petersen <martin.petersen@oracle.com> | 2025-11-12 21:08:05 -0500 |
| commit | 3813d28b2b12dea8f44a6828b9c30b38208d3fc5 (patch) | |
| tree | 95efd2a472ecb94d03b2e3a84ae8c897a71e71fd /drivers/scsi/lpfc/lpfc_init.c | |
| parent | 18987143d4b1945a1bfcb3963ae1961ca29b27dd (diff) | |
scsi: scsi_debug: Fix uninitialized pointers with __free attr
Uninitialized pointers with '__free' attribute can cause undefined
behaviour as the memory assigned(randomly) to the pointer is freed
automatically when the pointer goes out of scope
scsi doesn't have any bugs related to this as of now, but it is better
to initialize and assign pointers with '__free' attr in one statement to
ensure proper scope-based cleanup
Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
Closes: https://lore.kernel.org/all/aPiG_F5EBQUjZqsl@stanley.mountain/
Signed-off-by: Ally Heev <allyheev@gmail.com>
Link: https://patch.msgid.link/20251105-aheev-uninitialized-free-attr-scsi-v1-1-d28435a0a7ea@gmail.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_init.c')
0 files changed, 0 insertions, 0 deletions