public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Rusty Trivial Russell <rusty@rustcorp.com.au>
To: Marcelo Tosatti <marcelo@conectiva.com.br>
Cc: linux-scsi@vger.kernel.org
Subject: [TRIVIAL] [Trivial Patch] scsi_register-002
Date: Thu, 06 Feb 2003 14:11:34 +1100	[thread overview]
Message-ID: <20030206053821.CD22F2C397@lists.samba.org> (raw)

(Included in 2.5)
From:  Michael Still <mikal@stillhq.com>

  
  This patch has been generated as part of my scsi_register audit of the 2.5.45 kernel tree. scsi_register() can fail, returning a NULL pointer, and the failure case was not being handled here...
  
  
  
  

--- trivial-2.4.21-pre4/drivers/scsi/aacraid/linit.c.orig	2003-02-06 13:53:49.000000000 +1100
+++ trivial-2.4.21-pre4/drivers/scsi/aacraid/linit.c	2003-02-06 13:53:49.000000000 +1100
@@ -203,6 +203,9 @@
 			 * specific information.
 			 */
 			host_ptr = scsi_register( template, sizeof(struct aac_dev) );
+			if(host_ptr == NULL)
+				continue;
+
 			/* 
 			 * These three parameters can be used to allow for wide SCSI 
 			 * and for host adapters that support multiple buses.
-- 
  Don't blame me: the Monkey is driving
  File: Michael Still <mikal@stillhq.com>: [Trivial Patch] scsi_register-002

             reply	other threads:[~2003-02-06  3:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-06  3:11 Rusty Trivial Russell [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-06-23  6:56 [TRIVIAL] [Trivial Patch] scsi_register-002 Rusty Trivial Russell
2003-06-23 14:17 ` Alan Cox
2003-06-23 15:42   ` Rusty Russell
2002-12-16 10:39 Rusty Trivial Russell
2002-11-08  8:25 Rusty Trivial Russell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030206053821.CD22F2C397@lists.samba.org \
    --to=rusty@rustcorp.com.au \
    --cc=linux-scsi@vger.kernel.org \
    --cc=marcelo@conectiva.com.br \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox