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-next>] [day] [month] [year] [list]
Message-ID: <20190924020348.GD26530@ZenIV.linux.org.uk>
Date:   Tue, 24 Sep 2019 03:03:48 +0100
From:   Al Viro <viro@...iv.linux.org.uk>
To:     John Johansen <john.johansen@...onical.com>
Cc:     linux-kernel@...r.kernel.org
Subject: [WTF?] aafs_create_symlink() weirdness


static struct dentry *aafs_create_symlink(const char *name,
                                          struct dentry *parent,
                                          const char *target,
                                          void *private,
                                          const struct inode_operations *iops)
{
        struct dentry *dent;
        char *link = NULL;

        if (target) {
                if (!link)
                        return ERR_PTR(-ENOMEM);
        }

Er...  That's an odd way to spell
	if (target)
		return ERR_PTR(-ENOMEM);
(and an odd error value to use).  Especially since all callers are passing
NULL as target.

Why is that code even there, why does that argument still exist and
how many people have actually read that function?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ