Re: [PATCH v2 1/2] fs: replace const char* parameter in vfs_statx and do_statx with struct filename

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 2/14/22 5:15 PM, Al Viro wrote:
> On Mon, Feb 14, 2022 at 04:21:20PM -0800, Stefan Roesch wrote:
>>  {
>> -	return do_statx(dfd, filename, flags, mask, buffer);
>> +	int ret;
>> +	struct filename *name;
>> +
>> +	name = getname_flags(filename, getname_statx_lookup_flags(flags), NULL);
>> +	ret = do_statx(dfd, name, flags, mask, buffer);
>> +	if (name)
>> +		putname(name);
> 
> ... and the same comment goes for this one - getname... does *not*
> report a failure as NULL; it's ERR_PTR(), and putname(ERR_PTR(...))
> is an explicit no-op.

I addressed this with v3 of the patch.



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux