[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <54C12BD2.7040705@roeck-us.net>
Date: Thu, 22 Jan 2015 08:56:50 -0800
From: Guenter Roeck <linux@...ck-us.net>
To: Richard Guy Briggs <rgb@...hat.com>, Paul Moore <pmoore@...hat.com>
CC: linux-fsdevel@...r.kernel.org, linux-audit@...hat.com,
sd@...asysnail.net, linux-kernel@...r.kernel.org,
viro@...iv.linux.org.uk
Subject: Re: [PATCH v2 1/5] fs: rework getname_kernel to handle up to PATH_MAX
sized filenames
On 01/22/2015 07:53 AM, Richard Guy Briggs wrote:
> On 15/01/21, Paul Moore wrote:
>> In preparation for expanded use in the kernel, make getname_kernel()
>> more useful by allowing it to handle any legal filename length.
>>
>> Thanks to Guenter Roeck for his suggestion to substitute memcpy() for
>> strlcpy().
>>
>> CC: linux@...ck-us.net
>> CC: viro@...iv.linux.org.uk
>> CC: linux-fsdevel@...r.kernel.org
>> Signed-off-by: Paul Moore <pmoore@...hat.com>
>
> Noted memcpy() difference (I assume to avoid races).
>
It is more efficient to use memcpy if the string length is known.
Guenter
--
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