From: Julia Lawall Date: Wed, 11 Aug 2010 01:01:13 +0000 (-0700) Subject: drivers/scsi: remove unnecessary NULL test X-Git-Tag: v2.6.36-rc1~272 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=95cc7baa7f19e191b4790d144b7cbe47369cfe32;p=pandora-kernel.git drivers/scsi: remove unnecessary NULL test At the point where cmnd is initialized, it is tested for NULL, so it doesn't have to be tested again here. A simplified version of the semantic match that detects this problem is as follows (http://coccinelle.lip6.fr/): // @match exists@ expression x, E; identifier fld; @@ * x->fld ... when != \(x = E\|&x\) * x == NULL // Signed-off-by: Julia Lawall Cc: James Bottomley Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed