Anope IRC Services

Please login or register.

Login with username, password and session length
Advanced search  

News:

Pages: [1]   Go Down

Author Topic: db_old language import and encoding  (Read 1369 times)

0 Members and 1 Guest are viewing this topic.

capitaine

  • Anope User
  • Offline Offline
  • Posts: 38
    • http://www.coolsmile.net
db_old language import and encoding
« on: August 14, 2015, 11:32:23 AM »

Anope 2 default languages files are UTF-8 encoded, so I don't understand why the import module "db_old.cpp" does not specify UTF-8.

Code: [Select]
case LANG_ES:
nc->language = "es_ES";
break;
case LANG_PT:
nc->language = "pt_PT";
break;
case LANG_FR:
nc->language = "fr_FR";
break;
case LANG_TR:
nc->language = "tr_TR";

Currently, after a database conversion, it seems each user has to set manually its language setting to xx_XX.UTF-8.
If then don't do it, the language is switched to english.
IMO hardcoding UTF-8 in the conversion, as it is the default shipped with Anope 2, would be a better option.

Code: [Select]
case LANG_ES:
nc->language = "es_ES.UTF-8";
break;
case LANG_PT:
nc->language = "pt_PT.UTF-8";
break;
case LANG_FR:
nc->language = "fr_FR.UTF-8";
break;
case LANG_TR:
nc->language = "tr_TR.UTF-8";
Logged
Pages: [1]   Go Up