Whamcloud - gitweb
LU-4629 liblustre: remove suspicious check 24/9324/2
authorDmitry Eremin <dmitry.eremin@intel.com>
Fri, 14 Feb 2014 17:23:56 +0000 (21:23 +0400)
committerOleg Drokin <oleg.drokin@intel.com>
Sat, 1 Mar 2014 02:32:43 +0000 (02:32 +0000)
Suspicious dereference of pointer 'inode' by passing argument 1 to
function 'llu_i2info' at line 387 before NULL check at line 391.

The pointer 'inode' can not be NULL. This checked on upper layer.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Change-Id: Iea1e4d46f9faccf74a895002a8640959d63c395a
Reviewed-on: http://review.whamcloud.com/9324
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
lustre/liblustre/super.c

index 3f3788a..726e141 100644 (file)
@@ -388,11 +388,6 @@ static int llu_inode_revalidate(struct inode *inode)
         struct intnl_stat *st = llu_i2stat(inode);
         ENTRY;
 
         struct intnl_stat *st = llu_i2stat(inode);
         ENTRY;
 
-        if (!inode) {
-                CERROR("REPORT THIS LINE TO PETER\n");
-                RETURN(0);
-        }
-
         if (!llu_have_md_lock(inode, MDS_INODELOCK_UPDATE)) {
                 struct lustre_md md;
                 struct ptlrpc_request *req = NULL;
         if (!llu_have_md_lock(inode, MDS_INODELOCK_UPDATE)) {
                 struct lustre_md md;
                 struct ptlrpc_request *req = NULL;