From 8eac8ee52a3711174c04b5d662a8953181adc8a0 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 3 Oct 2018 11:22:22 -0600 Subject: [PATCH] Trivial updates after review of last merge. --- libs/libc/stdio/lib_sscanf.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/libs/libc/stdio/lib_sscanf.c b/libs/libc/stdio/lib_sscanf.c index c436056425..d4dc43ee66 100644 --- a/libs/libc/stdio/lib_sscanf.c +++ b/libs/libc/stdio/lib_sscanf.c @@ -779,7 +779,7 @@ int vsscanf(FAR const char *buf, FAR const char *fmt, va_list ap) if (*buf) { FAR char *endptr; - int errsave; + int errsave; #ifdef CONFIG_HAVE_DOUBLE double dvalue; #endif @@ -839,6 +839,7 @@ int vsscanf(FAR const char *buf, FAR const char *fmt, va_list ap) buf += (endptr - tmp); set_errno(errsave); + if (!noassign) { @@ -849,7 +850,6 @@ int vsscanf(FAR const char *buf, FAR const char *fmt, va_list ap) #ifdef CONFIG_HAVE_DOUBLE if (lflag) { - /* Return the double value */ linfo("vsscanf: Return %f to %p\n", dvalue, pd); @@ -858,7 +858,6 @@ int vsscanf(FAR const char *buf, FAR const char *fmt, va_list ap) else #endif { - /* Return the float value */ linfo("vsscanf: Return %f to %p\n", (double)fvalue, pf);