From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 45999 invoked by alias); 10 Oct 2018 09:21:12 -0000 Mailing-List: contact newlib-cvs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: newlib-cvs-owner@sourceware.org Received: (qmail 43229 invoked by uid 9078); 10 Oct 2018 09:18:54 -0000 Date: Wed, 10 Oct 2018 09:21:00 -0000 Message-ID: <20181010091854.43226.qmail@sourceware.org> Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Corinna Vinschen To: newlib-cvs@sourceware.org Subject: [newlib-cygwin] newlib: Drop incorrect const qualifier from __loadlocale parameter X-Act-Checkin: newlib-cygwin X-Git-Author: Corinna Vinschen X-Git-Refname: refs/heads/master X-Git-Oldrev: 201bbec6e4266ad95e78c1d88e86c233140435ea X-Git-Newrev: 9479563e4836177414c995730adb96d48da9fb22 X-SW-Source: 2018-q4/txt/msg00006.txt.bz2 https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=9479563e4836177414c995730adb96d48da9fb22 commit 9479563e4836177414c995730adb96d48da9fb22 Author: Corinna Vinschen Date: Wed Oct 10 11:18:02 2018 +0200 newlib: Drop incorrect const qualifier from __loadlocale parameter Signed-off-by: Corinna Vinschen Diff: --- newlib/libc/locale/locale.c | 4 ++-- newlib/libc/locale/setlocale.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/newlib/libc/locale/locale.c b/newlib/libc/locale/locale.c index 791a775..4c343e4 100644 --- a/newlib/libc/locale/locale.c +++ b/newlib/libc/locale/locale.c @@ -463,7 +463,7 @@ currentlocale () extern void __set_ctype (struct __locale_t *, const char *charset); char * -__loadlocale (struct __locale_t *loc, int category, const char *new_locale) +__loadlocale (struct __locale_t *loc, int category, char *new_locale) { /* At this point a full-featured system would just load the locale specific data from the locale files. @@ -506,7 +506,7 @@ __loadlocale (struct __locale_t *loc, int category, const char *new_locale) restart: if (!locale) - locale = (char *) new_locale; + locale = new_locale; else if (locale != tmp_locale) { locale = __set_locale_from_locale_alias (locale, tmp_locale); diff --git a/newlib/libc/locale/setlocale.h b/newlib/libc/locale/setlocale.h index 25c27cf..a0c8084 100644 --- a/newlib/libc/locale/setlocale.h +++ b/newlib/libc/locale/setlocale.h @@ -195,7 +195,7 @@ struct __locale_t }; #ifdef _MB_CAPABLE -extern char *__loadlocale (struct __locale_t *, int, const char *); +extern char *__loadlocale (struct __locale_t *, int, char *); extern const char *__get_locale_env(struct _reent *, int); #endif /* _MB_CAPABLE */