mirror of
https://github.com/moparisthebest/curl
synced 2024-08-13 17:03:50 -04:00
tool_operate: Moved locale setup code into operate_init()
This commit is contained in:
parent
06b4275c0d
commit
61ba1daba0
@ -193,6 +193,11 @@ static CURLcode operate_init(struct Configurable *config)
|
||||
return CURLE_FAILED_INIT;
|
||||
}
|
||||
|
||||
/* Setup proper locale from environment */
|
||||
#ifdef HAVE_SETLOCALE
|
||||
setlocale(LC_ALL, "");
|
||||
#endif
|
||||
|
||||
return CURLE_OK;
|
||||
}
|
||||
|
||||
@ -230,11 +235,6 @@ static int operate_do(struct Configurable *config, int argc,
|
||||
** from outside of nested loops further down below.
|
||||
*/
|
||||
|
||||
/* setup proper locale from environment */
|
||||
#ifdef HAVE_SETLOCALE
|
||||
setlocale(LC_ALL, "");
|
||||
#endif
|
||||
|
||||
/* Parse .curlrc if necessary */
|
||||
if((argc == 1) || (!curlx_strequal(argv[1], "-q"))) {
|
||||
parseconfig(NULL, config); /* ignore possible failure */
|
||||
|
Loading…
Reference in New Issue
Block a user