Whamcloud - gitweb
- fix case when inode can be NULL.
authortappro <tappro>
Fri, 26 Aug 2005 11:44:26 +0000 (11:44 +0000)
committertappro <tappro>
Fri, 26 Aug 2005 11:44:26 +0000 (11:44 +0000)
lustre/smfs/audit.c

index 8134204..47baa0e 100644 (file)
@@ -272,7 +272,7 @@ int smfs_set_audit(struct super_block * sb, struct inode * inode,
 {
         void * handle = NULL;
         struct fsfilt_operations * fsfilt = S2SMI(sb)->sm_fsfilt;
-        struct smfs_inode_info *smi = I2SMI(inode);
+        struct smfs_inode_info *smi = NULL;
         int rc = 0;
         
         ENTRY;
@@ -281,7 +281,7 @@ int smfs_set_audit(struct super_block * sb, struct inode * inode,
                 return smfs_set_fs_audit(sb, mask);
 
         LASSERT(inode);
-        
+        smi = I2SMI(inode);
         handle = fsfilt->fs_start(inode, FSFILT_OP_SETATTR, NULL, 0);
         if (IS_ERR(handle))
                 RETURN(PTR_ERR(handle));