linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drivers/ide/ide-tape.c: remove double kfree
@ 2008-06-28 22:34 Darren Jenkins\
  2008-06-29 16:26 ` Borislav Petkov
  0 siblings, 1 reply; 3+ messages in thread
From: Darren Jenkins\ @ 2008-06-28 22:34 UTC (permalink / raw)
  To: kernel Janitors, LKML, linux-ide, gadio

G'day people,


Coverity CID: 2336 USE_AFTER_FREE

drivers/ide/ide-tape.c ide_tape_kfree_buffer() double free's a pointer
(hint freed by an alias in first outer loop).
This patch simply removes the superfluous kfree().



Signed-off-by: Darren Jenkins <darrenrjenkins@gmailcom>


diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c
index 1e1f263..86164be 100644
--- a/drivers/ide/ide-tape.c
+++ b/drivers/ide/ide-tape.c
@@ -600,7 +600,6 @@ static void ide_tape_kfree_buffer(idetape_tape_t *tape)
 		bh = bh->b_reqnext;
 		kfree(prev_bh);
 	}
-	kfree(tape->merge_bh);
 }
 
 static int idetape_end_request(ide_drive_t *drive, int uptodate, int nr_sects)



^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-06-30 21:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-28 22:34 [PATCH] drivers/ide/ide-tape.c: remove double kfree Darren Jenkins\
2008-06-29 16:26 ` Borislav Petkov
2008-06-30 20:45   ` Bartlomiej Zolnierkiewicz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).