[patch] UTF-8: Reuse the translation table if it is from the same charset.

Kalle Olavi Niemitalo <[email protected]>
Newsgroups gmane.comp.web.links
Message-ID <[email protected]>
_______________________________________________
elinks-dev mailing list
[email protected]
http://linuxfromscratch.org/mailman/listinfo/elinks-dev
(unnamed) (text/x-patch, 997 B)
UTF-8: Reuse the translation table if it is from the same charset.

This change makes ELinks more efficient and causes bug 782 to occur
far less often.  (That does not mean the bug should not be fixed.)

---
commit 0b7cee1e6e763b9de3e49846ecc14f41ed9a6fdb
tree 8396aabcb8e0522f03fcddee2c7af241d2fbe999
parent 5d88a5dc49a87d3abfbd14653ce7de6a88014135
author Kalle Olavi Niemitalo <[email protected]> Mon, 31 Jul 2006 20:21:10 +0300
committer Kalle Olavi Niemitalo <[email protected]> Mon, 31 Jul 2006 20:21:10 +0300

 src/intl/charsets.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/src/intl/charsets.c b/src/intl/charsets.c
index dd0ee5b..33bc507 100644
--- a/src/intl/charsets.c
+++ b/src/intl/charsets.c
@@ -527,6 +527,7 @@ get_translation_table_to_utf_8(int from)
 	if (from == -1) return NULL;
 	from &= ~SYSTEM_CHARSET_FLAG;
 	if (from == lfr) return utf_table;
+	lfr = from;
 	if (utf_table_init)
 		memset(utf_table, 0, sizeof(utf_table)),
 		utf_table_init = 0;
signature.asc (application/pgp-signature, 188 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)

iD8DBQFEzjy3Hm9IGt60eMgRAi8wAKCsKyFBi1JzKhp+bbgG8QA2cXTOFgCg0U79
4pE8DoMWoTAIkokuvKdzbmY=
=mk37
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.