]> git.karo-electronics.de Git - linux-beck.git/commitdiff
cifs: change && to ||
authorDan Carpenter <error27@gmail.com>
Mon, 26 Apr 2010 10:10:06 +0000 (12:10 +0200)
committerSteve French <sfrench@us.ibm.com>
Mon, 26 Apr 2010 19:08:01 +0000 (19:08 +0000)
This is a typo, if pvolume_info were NULL it would oops.

This function is used in clean up and error handling.  The current code
never passes a NULL pvolume_info, but it could pass a NULL *pvolume_info
if the kmalloc() failed.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <sfrench@us.ibm.com>
fs/cifs/connect.c

index c2793bd1db4a5c8a3861adbb686292720f961a2b..7a47c7c5c7e3d4c58e6d113ba80b22f14aa58a09 100644 (file)
@@ -2421,7 +2421,7 @@ cleanup_volume_info(struct smb_vol **pvolume_info)
 {
        struct smb_vol *volume_info;
 
-       if (!pvolume_info && !*pvolume_info)
+       if (!pvolume_info || !*pvolume_info)
                return;
 
        volume_info = *pvolume_info;