diff options
author | Igor Druzhinin <igor.druzhinin@citrix.com> | 2020-01-14 17:43:19 +0300 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2020-02-22 01:56:32 +0300 |
commit | ff6993bb79b9f99bdac0b5378169052931b65432 (patch) | |
tree | 12a7e43baf679037eccbcbb7f4e771a36defee18 /drivers/scsi/libfc/fc_disc.c | |
parent | 807b9515b7d044cf77df31f1af9d842a76ecd5cb (diff) | |
download | linux-ff6993bb79b9f99bdac0b5378169052931b65432.tar.xz |
scsi: libfc: free response frame from GPN_ID
fc_disc_gpn_id_resp() should be the last function using it so free it here
to avoid memory leak.
Link: https://lore.kernel.org/r/1579013000-14570-2-git-send-email-igor.druzhinin@citrix.com
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Igor Druzhinin <igor.druzhinin@citrix.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/libfc/fc_disc.c')
-rw-r--r-- | drivers/scsi/libfc/fc_disc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/scsi/libfc/fc_disc.c b/drivers/scsi/libfc/fc_disc.c index 9c5f7c9178c6..2b865c6423e2 100644 --- a/drivers/scsi/libfc/fc_disc.c +++ b/drivers/scsi/libfc/fc_disc.c @@ -628,6 +628,8 @@ redisc: } out: kref_put(&rdata->kref, fc_rport_destroy); + if (!IS_ERR(fp)) + fc_frame_free(fp); } /** |