diff options
author | Manuel Novoa III <mjn3@codepoet.org> | 2003-12-14 19:10:23 +0000 |
---|---|---|
committer | Manuel Novoa III <mjn3@codepoet.org> | 2003-12-14 19:10:23 +0000 |
commit | edcbb2ecce1455995c5990fb5f39d14881b809fa (patch) | |
tree | aa6ba630a3cee460cb30471235d263181aa13ef5 /libc | |
parent | 58d6ac1dcef87b61bdb5844108e9774c40d3976e (diff) | |
download | uClibc-alpine-edcbb2ecce1455995c5990fb5f39d14881b809fa.tar.bz2 uClibc-alpine-edcbb2ecce1455995c5990fb5f39d14881b809fa.tar.xz |
Fix a couple of 'declaration after statement' errors.
Diffstat (limited to 'libc')
-rw-r--r-- | libc/misc/locale/locale.c | 3 | ||||
-rw-r--r-- | libc/stdio/scanf.c | 2 |
2 files changed, 2 insertions, 3 deletions
diff --git a/libc/misc/locale/locale.c b/libc/misc/locale/locale.c index 1e79204c0..cf058ce3e 100644 --- a/libc/misc/locale/locale.c +++ b/libc/misc/locale/locale.c @@ -1378,9 +1378,8 @@ __locale_t weak_const_function __curlocale(void) __locale_t weak_function __curlocale_set(__locale_t newloc) { - assert(newloc != LC_GLOBAL_LOCALE); - __locale_t oldloc = __curlocale_var; + assert(newloc != LC_GLOBAL_LOCALE); __curlocale_var = newloc; return oldloc; } diff --git a/libc/stdio/scanf.c b/libc/stdio/scanf.c index ac5bf9931..b1299196f 100644 --- a/libc/stdio/scanf.c +++ b/libc/stdio/scanf.c @@ -1119,8 +1119,8 @@ int VFSCANF (FILE *__restrict fp, const Wchar *__restrict format, va_list arg) /* ANSI/ISO C99 requires format string to be a valid multibyte string * beginning and ending in its initial shift state. */ if (((__UCLIBC_CURLOCALE_DATA).encoding) != __ctype_encoding_7_bit) { - mbstate.mask = 0; /* Initialize the mbstate. */ const char *p = format; + mbstate.mask = 0; /* Initialize the mbstate. */ if (mbsrtowcs(NULL, &p, SIZE_MAX, &mbstate) == ((size_t)(-1))) { __set_errno(EINVAL); /* Format string is invalid. */ return 0; |