mirror of
https://github.com/tesseract-ocr/tesseract.git
synced 2024-11-24 02:59:07 +08:00
Merge pull request #2272 from nijel/patch-1
Allow UTF-8 variant of C locale
This commit is contained in:
commit
13bd96fd37
@ -208,11 +208,11 @@ TessBaseAPI::TessBaseAPI()
|
||||
image_height_(0) {
|
||||
const char *locale;
|
||||
locale = std::setlocale(LC_ALL, nullptr);
|
||||
ASSERT_HOST(!strcmp(locale, "C"));
|
||||
ASSERT_HOST(!strcmp(locale, "C") || !strcmp(locale, "C.UTF-8"));
|
||||
locale = std::setlocale(LC_CTYPE, nullptr);
|
||||
ASSERT_HOST(!strcmp(locale, "C"));
|
||||
ASSERT_HOST(!strcmp(locale, "C") || !strcmp(locale, "C.UTF-8"));
|
||||
locale = std::setlocale(LC_NUMERIC, nullptr);
|
||||
ASSERT_HOST(!strcmp(locale, "C"));
|
||||
ASSERT_HOST(!strcmp(locale, "C") || !strcmp(locale, "C.UTF-8"));
|
||||
}
|
||||
|
||||
TessBaseAPI::~TessBaseAPI() {
|
||||
|
Loading…
Reference in New Issue
Block a user