From ecdec2b5a6ac21a978779748328144a1aec6b030 Mon Sep 17 00:00:00 2001 From: Abs62 Date: Fri, 7 Jul 2017 17:16:33 +0300 Subject: [PATCH] Bgl: Fix conversion for Eastern European encoding --- bgl_babylon.cc | 5 ----- bgl_babylon.hh | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/bgl_babylon.cc b/bgl_babylon.cc index 405b44e0..caabc95a 100644 --- a/bgl_babylon.cc +++ b/bgl_babylon.cc @@ -210,12 +210,9 @@ bool Babylon::read(std::string &source_charset, std::string &target_charset) { case 8: type = (unsigned int)block.data[2]; - if( type == 67 ) type = 1; if( type > 64 ) type -= 65; - if ( type >= 14 ) type = 0; - m_defaultCharset = bgl_charset[type]; break; default: @@ -284,7 +281,6 @@ bool Babylon::read(std::string &source_charset, std::string &target_charset) break; case 26: type = (unsigned int)block.data[2]; - if( type == 67 ) type = 1; if( type > 64 ) type -= 65; if ( type >= 14 ) type = 0; @@ -293,7 +289,6 @@ bool Babylon::read(std::string &source_charset, std::string &target_charset) break; case 27: type = (unsigned int)block.data[2]; - if( type == 67 ) type = 1; if( type > 64 ) type -= 65; if ( type >= 14 ) type = 0; diff --git a/bgl_babylon.hh b/bgl_babylon.hh index 89c9b8d3..2947c338 100644 --- a/bgl_babylon.hh +++ b/bgl_babylon.hh @@ -120,7 +120,7 @@ const std::string bgl_charsetname[] = { const std::string bgl_charset[] = { "WINDOWS-1252", /*Default*/ "WINDOWS-1252", /*Latin*/ - "ISO-8859-2", /*Eastern European*/ + "WINDOWS-1250", /*Eastern European*/ "WINDOWS-1251", /*Cyriilic*/ "CP932", /*Japanese*/ "BIG5", /*Traditional Chinese*/