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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 27 Oct 2010 12:14:32 -0400
From:	Christoph Hellwig <hch@...radead.org>
To:	Jeff Layton <jlayton@...hat.com>
Cc:	Jiri Slaby <jslaby@...e.cz>, sfrench@...ba.org,
	linux-kernel@...r.kernel.org, jirislaby@...il.com,
	linux-cifs@...r.kernel.org
Subject: Re: [PATCH 2/4] FS: cifs, remove unneeded NULL tests

On Wed, Oct 27, 2010 at 12:13:38PM -0400, Jeff Layton wrote:
> > diff --git a/fs/cifs/file.c b/fs/cifs/file.c
> > index 45af003..db7eaf7 100644
> > --- a/fs/cifs/file.c
> > +++ b/fs/cifs/file.c
> > @@ -1031,7 +1031,7 @@ ssize_t cifs_user_write(struct file *file, const char __user *write_data,
> >  	cifs_stats_bytes_written(pTcon, total_written);
> >  
> >  	/* since the write may have blocked check these pointers again */
> > -	if ((file->f_path.dentry) && (file->f_path.dentry->d_inode)) {
> > +	if (file->f_path.dentry->d_inode) {
> 
> 		^^^^^^
> 	This check is bogus too. An open filp on a negative dentry
> 	isn't possible, right?

Indeed, it's impossible.

--
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