Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't try to change locale when libc only supports the C locale #777

Closed
wants to merge 1 commit into from

Conversation

jameshilliard
Copy link

When uclibc is build only with C locale support we don't need to try and change to the C locale.

When uclibc is build only with C locale support we don't need to
try and change to the C locale.
@@ -298,11 +298,13 @@ struct json_object *json_tokener_parse_ex(struct json_tokener *tok, const char *
unsigned int nBytes = 0;
unsigned int *nBytesp = &nBytes;

#ifndef __LOCALE_C_ONLY
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where does __LOCALE_C_ONLY get set? I would expect to see something in CMakeLists.txt

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should get set by uclibc's locale.h header.

@hawicz
Copy link
Member

hawicz commented Jul 31, 2022

It turns out that even with locale support available, uClibc's duplocale() is crashes (see issue #705) so I ended up changing CMakeLists.txt to entirely disable locale handling there. With that in place, I believe this PR is unnecessary.

@hawicz hawicz closed this Jul 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants