[PATCH] JFFS2: Add parameter to reserve disk space for root

David Woodhouse dwmw2 at infradead.org
Tue May 15 11:06:44 EDT 2012


On Tue, 2012-04-10 at 22:22 +0100, Daniel Drake wrote:
> 
> +       /* Always allow root */
> +       if (current_fsuid() == 0 || current_fsgid() == 0)
> +               return 1; 

I've changed that to if (capable(CAP_SYS_RESOURCE)) rather than having a
hard-coded check for the root user, which is usually the wrong thing to
do. Please test.

-- 
dwmw2
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 6171 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-mtd/attachments/20120515/b6f1a97e/attachment.bin>


More information about the linux-mtd mailing list