[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1524668194.21176.557.camel@linux.intel.com>
Date: Wed, 25 Apr 2018 17:56:34 +0300
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Petr Mladek <pmladek@...e.com>,
Rasmus Villemoes <linux@...musvillemoes.dk>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>,
"Tobin C . Harding" <me@...in.cc>, Joe Perches <joe@...ches.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Michal Hocko <mhocko@...e.cz>,
Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
Steven Rostedt <rostedt@...dmis.org>,
Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5 07/11] vsprintf: Factor out %pV handler as va_format()
On Wed, 2018-04-25 at 13:12 +0200, Petr Mladek wrote:
> Move the code from the long pointer() function. We are going to add a
> check
> for the access to the address that will make it even more complicated.
>
> This patch does not change the existing behavior.
> +static char *va_format(char *buf, char *end, struct va_format
> *va_fmt)
> +{
> + va_list va;
> +
> + va_copy(va, *va_fmt->va);
> + buf += vsnprintf(buf, end > buf ? end - buf : 0,
> + va_fmt->fmt, va);
One line?
> + va_end(va);
> +
> + return buf;
> +}
--
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Intel Finland Oy
Powered by blists - more mailing lists