diff options
author | Arnd Bergmann <arnd@arndb.de> | 2012-03-24 20:13:59 +0100 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2012-03-24 20:13:59 +0100 |
commit | 83fe628e16d84efc8df2731bc403eae4e4f53801 (patch) | |
tree | 9a51c292235621d0f4f632c2a55ddb5a6ab582af /lib/vsprintf.c | |
parent | Merge branch 'samsung/soc' into next/soc2 (diff) | |
parent | Merge branch 'rmobile-fixes-for-linus' of git://github.com/pmundt/linux-sh in... (diff) | |
download | linux-83fe628e16d84efc8df2731bc403eae4e4f53801.tar.xz linux-83fe628e16d84efc8df2731bc403eae4e4f53801.zip |
Merge branch 'renesas/soc' into next/soc2
Diffstat (limited to 'lib/vsprintf.c')
-rw-r--r-- | lib/vsprintf.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/lib/vsprintf.c b/lib/vsprintf.c index 8e75003d62f6..38e612e66da5 100644 --- a/lib/vsprintf.c +++ b/lib/vsprintf.c @@ -891,9 +891,15 @@ char *pointer(const char *fmt, char *buf, char *end, void *ptr, case 'U': return uuid_string(buf, end, ptr, spec, fmt); case 'V': - return buf + vsnprintf(buf, end > buf ? end - buf : 0, - ((struct va_format *)ptr)->fmt, - *(((struct va_format *)ptr)->va)); + { + va_list va; + + va_copy(va, *((struct va_format *)ptr)->va); + buf += vsnprintf(buf, end > buf ? end - buf : 0, + ((struct va_format *)ptr)->fmt, va); + va_end(va); + return buf; + } case 'K': /* * %pK cannot be used in IRQ context because its test |