mirror of
https://github.com/moparisthebest/curl
synced 2024-08-13 17:03:50 -04:00
Peter Wullinger pointed out that curl should call setlocale() properly to
initiate the specific language operations, to make the IDN stuff work better.
This commit is contained in:
parent
48750d5fc7
commit
82d6cfa7fc
5
CHANGES
5
CHANGES
@ -6,6 +6,11 @@
|
|||||||
|
|
||||||
Changelog
|
Changelog
|
||||||
|
|
||||||
|
Daniel (18 October 2004)
|
||||||
|
- Peter Wullinger pointed out that curl should call setlocale() properly to
|
||||||
|
initiate the specific language operations, to make the IDN stuff work
|
||||||
|
better.
|
||||||
|
|
||||||
Version 7.12.2 (18 October 2004)
|
Version 7.12.2 (18 October 2004)
|
||||||
|
|
||||||
Daniel (16 October 2004)
|
Daniel (16 October 2004)
|
||||||
|
@ -1121,6 +1121,7 @@ AC_CHECK_HEADERS(
|
|||||||
sys/utime.h \
|
sys/utime.h \
|
||||||
sys/poll.h \
|
sys/poll.h \
|
||||||
libgen.h \
|
libgen.h \
|
||||||
|
locale.h \
|
||||||
setjmp.h,
|
setjmp.h,
|
||||||
dnl to do if not found
|
dnl to do if not found
|
||||||
[],
|
[],
|
||||||
@ -1217,6 +1218,7 @@ AC_CHECK_FUNCS( strtoll \
|
|||||||
utime \
|
utime \
|
||||||
sigsetjmp \
|
sigsetjmp \
|
||||||
basename \
|
basename \
|
||||||
|
setlocale \
|
||||||
poll,
|
poll,
|
||||||
dnl if found
|
dnl if found
|
||||||
[],
|
[],
|
||||||
|
@ -95,6 +95,12 @@
|
|||||||
/* Define if you have the <limits.h> header file */
|
/* Define if you have the <limits.h> header file */
|
||||||
#undef HAVE_LIMITS_H
|
#undef HAVE_LIMITS_H
|
||||||
|
|
||||||
|
/* Define to 1 if you have the <locale.h> header file. */
|
||||||
|
#undef HAVE_LOCALE_H
|
||||||
|
|
||||||
|
/* Define to 1 if you have the `setlocale' function. */
|
||||||
|
#undef HAVE_SETLOCALE
|
||||||
|
|
||||||
/* type to use in place of socklen_t if not defined */
|
/* type to use in place of socklen_t if not defined */
|
||||||
#undef socklen_t
|
#undef socklen_t
|
||||||
|
|
||||||
|
11
src/main.c
11
src/main.c
@ -90,7 +90,7 @@
|
|||||||
#include <sys/utime.h>
|
#include <sys/utime.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif /* HAVE_UTIME_H */
|
||||||
|
|
||||||
#ifdef HAVE_LIMITS_H
|
#ifdef HAVE_LIMITS_H
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
@ -100,6 +100,10 @@
|
|||||||
#include <sys/poll.h>
|
#include <sys/poll.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_LOCALE_H
|
||||||
|
#include <locale.h> /* for setlocale() */
|
||||||
|
#endif
|
||||||
|
|
||||||
#define ENABLE_CURLX_PRINTF
|
#define ENABLE_CURLX_PRINTF
|
||||||
/* make the curlx header define all printf() functions to use the curlx_*
|
/* make the curlx header define all printf() functions to use the curlx_*
|
||||||
versions instead */
|
versions instead */
|
||||||
@ -2790,6 +2794,11 @@ operate(struct Configurable *config, int argc, char *argv[])
|
|||||||
|
|
||||||
errorbuffer[0]=0; /* prevent junk from being output */
|
errorbuffer[0]=0; /* prevent junk from being output */
|
||||||
|
|
||||||
|
/* setup proper locale from environment */
|
||||||
|
#ifdef HAVE_SETLOCALE
|
||||||
|
setlocale(LC_ALL, "");
|
||||||
|
#endif
|
||||||
|
|
||||||
/* inits */
|
/* inits */
|
||||||
if (main_init() != CURLE_OK) {
|
if (main_init() != CURLE_OK) {
|
||||||
helpf("error initializing curl library\n");
|
helpf("error initializing curl library\n");
|
||||||
|
Loading…
Reference in New Issue
Block a user