[PATCH v2 2/4] string: Allow 2-argument strscpy()

Andy Shevchenko andy at kernel.org
Mon Feb 5 04:58:21 PST 2024


On Mon, Feb 05, 2024 at 01:47:08PM +0100, Geert Uytterhoeven wrote:
> On Mon, Feb 5, 2024 at 1:37 PM Kees Cook <keescook at chromium.org> wrote:

...

> > +#define __strscpy1(dst, src, size)     sized_strscpy(dst, src, size)
> 
> (dst), (src), (size) etc.

No need.

...

> > +#define strscpy(dst, src, ...) \
> > +       CONCATENATE(__strscpy, COUNT_ARGS(__VA_ARGS__))(dst, src, __VA_ARGS__)
> 
> Likewise

Likewise

-- 
With Best Regards,
Andy Shevchenko





More information about the linux-um mailing list