lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 3 Nov 2010 10:00:12 +0000
From:	Al Viro <viro@...IV.linux.org.uk>
To:	Jiri Slaby <jslaby@...e.cz>
Cc:	sfrench@...ba.org, linux-fsdevel@...r.kernel.org,
	linux-kernel@...r.kernel.org, jirislaby@...il.com,
	linux-cifs@...r.kernel.org, Jeff Layton <jlayton@...hat.com>,
	Christoph Hellwig <hch@...radead.org>
Subject: Re: [PATCH v2 1/1] FS: cifs, remove unneeded NULL tests

On Mon, Nov 01, 2010 at 04:08:55PM +0100, Jiri Slaby wrote:
> Stanse found that pSMBFile in cifs_ioctl and file->f_path.dentry in
> cifs_user_write are dereferenced prior their test to NULL.

file->f_path.dentry is never NULL for an opened file, neither is
file->f_path.dentry->d_inode (which cannot change for the entire
lifetime of dentry, BTW).  IOW,

> -	/* since the write may have blocked check these pointers again */
> -	if ((file->f_path.dentry) && (file->f_path.dentry->d_inode)) {
> -		struct inode *inode = file->f_path.dentry->d_inode;

in there had always been junk.  So yes, losing these tests is the right
thing to do.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ