* [PATCH] ide-cd: fix another NULL ptr in debug statement
@ 2008-09-25 7:51 Borislav Petkov
2008-09-27 16:27 ` Bartlomiej Zolnierkiewicz
0 siblings, 1 reply; 2+ messages in thread
From: Borislav Petkov @ 2008-09-25 7:51 UTC (permalink / raw)
To: bzolnier; +Cc: linux-kernel, linux-ide
Hi Bart,
here's another null ptr fix in the debugging code. I'll be auditing all the
debug fragments in case I've missed some.
---
From: Borislav Petkov <petkovbb@gmail.com>
Date: Thu, 25 Sep 2008 09:36:26 +0200
Subject: [PATCH] ide-cd: fix another NULL ptr in debug statement
There should be no functionality change resulting from this patch.
Signed-off-by: Borislav Petkov <petkovbb@gmail.com>
---
drivers/ide/ide-cd.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
index 5ed925d..c830817 100644
--- a/drivers/ide/ide-cd.c
+++ b/drivers/ide/ide-cd.c
@@ -166,10 +166,13 @@ static void cdrom_analyze_sense_data(ide_drive_t *drive,
unsigned long bio_sectors;
struct cdrom_info *info = drive->driver_data;
- ide_debug_log(IDE_DBG_SENSE, "Call %s, failed cmd: 0x%x, "
- "error_code: 0x%x, sense_key: 0x%x\n",
- __func__, failed_command->cmd[0], sense->error_code,
- sense->sense_key);
+ ide_debug_log(IDE_DBG_SENSE, "Call %s, error_code: 0x%x, "
+ "sense_key: 0x%x\n", __func__, sense->error_code,
+ sense->sense_key);
+
+ if (failed_command)
+ ide_debug_log(IDE_DBG_SENSE, "%s: failed cmd: 0x%x\n",
+ __func__, failed_command->cmd[0]);
if (!cdrom_log_sense(drive, failed_command, sense))
return;
--
1.5.5.4
--
Regards/Gruss,
Boris.
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ide-cd: fix another NULL ptr in debug statement
2008-09-25 7:51 [PATCH] ide-cd: fix another NULL ptr in debug statement Borislav Petkov
@ 2008-09-27 16:27 ` Bartlomiej Zolnierkiewicz
0 siblings, 0 replies; 2+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2008-09-27 16:27 UTC (permalink / raw)
To: petkovbb; +Cc: linux-kernel, linux-ide
On Thursday 25 September 2008, Borislav Petkov wrote:
> Hi Bart,
>
> here's another null ptr fix in the debugging code. I'll be auditing all the
> debug fragments in case I've missed some.
also merged into the original patch
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-09-27 17:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-25 7:51 [PATCH] ide-cd: fix another NULL ptr in debug statement Borislav Petkov
2008-09-27 16:27 ` 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).