From 6e8c9c3a873bc334c3c4acd2c7be41b7900d03e0 Mon Sep 17 00:00:00 2001 From: robertmh Date: Fri, 27 Feb 2009 21:27:01 +0000 Subject: [PATCH] 2009-02-27 Vladimir Serbinenko Don't leak in SCSI code. * disk/scsi.c (grub_scsi_close): free `scsi'. --- ChangeLog | 5 +++++ disk/scsi.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 711030629..206dc8c3d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-02-27 Vladimir Serbinenko + + Don't leak in SCSI code. + * disk/scsi.c (grub_scsi_close): free `scsi'. + 2009-02-27 Robert Millan * loader/i386/pc/multiboot.c: Move from here ... diff --git a/disk/scsi.c b/disk/scsi.c index 5dce28873..75b92b409 100644 --- a/disk/scsi.c +++ b/disk/scsi.c @@ -312,7 +312,8 @@ grub_scsi_close (grub_disk_t disk) grub_scsi_t scsi; scsi = disk->data; - return scsi->dev->close (scsi); + scsi->dev->close (scsi); + grub_free (scsi); } static grub_err_t