Re: [PATCH 3/4] samples/vfs: check whether flag was raised

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

 



On Thu, 30 Jan 2025 at 00:20, Christian Brauner <brauner@xxxxxxxxxx> wrote:
>
> For string options the kernel will raise the corresponding flag only if
> the string isn't empty. So check for the flag.

Hmm, seems like this is going to be a common mistake.

How about just putting a nul char at sm->str, which will solve this
once and for all (any unset str_ offset will point to this empty
string)?

Then we can say that instead of checking the mask for a string it's
okay to rely on it being empty by default.

Thanks,
Miklos




[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