aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsimonb <simonb>2006-05-20 15:23:54 (GMT)
committersimonb <simonb>2006-05-20 15:23:54 (GMT)
commit460f57a4ad63001e5ae2b3f9df763ba27aec5727 (patch)
treef9e1d6c80650fb80960c9e4b0514f10b5cc920df
parent70a834f80c1bfba456a20641138a5cfbe1fe4797 (diff)
downloadfluxbox_paul-460f57a4ad63001e5ae2b3f9df763ba27aec5727.zip
fluxbox_paul-460f57a4ad63001e5ae2b3f9df763ba27aec5727.tar.bz2
fix error when running with -i (or similar "don't start Fluxbox class"
options
-rw-r--r--src/FbTk/FbString.cc5
-rw-r--r--src/FbTk/I18n.cc1
2 files changed, 6 insertions, 0 deletions
diff --git a/src/FbTk/FbString.cc b/src/FbTk/FbString.cc
index 6c5ffbb..9a575bf 100644
--- a/src/FbTk/FbString.cc
+++ b/src/FbTk/FbString.cc
@@ -54,6 +54,11 @@ static int iconv_convs[CONVSIZE];
54 54
55/// Initialise all of the iconv conversion descriptors 55/// Initialise all of the iconv conversion descriptors
56void init() { 56void init() {
57 static bool s_init = false;
58 if (s_init)
59 return;
60 s_init = true;
61
57 iconv_convs = new iconv_t[CONVSIZE]; 62 iconv_convs = new iconv_t[CONVSIZE];
58 63
59 setlocale(LC_CTYPE, ""); 64 setlocale(LC_CTYPE, "");
diff --git a/src/FbTk/I18n.cc b/src/FbTk/I18n.cc
index 62fda06..43af752 100644
--- a/src/FbTk/I18n.cc
+++ b/src/FbTk/I18n.cc
@@ -66,6 +66,7 @@ using std::string;
66namespace FbTk { 66namespace FbTk {
67 67
68void NLSInit(const char *catalog) { 68void NLSInit(const char *catalog) {
69 FbStringUtil::init();
69 I18n *i18n = I18n::instance(); 70 I18n *i18n = I18n::instance();
70 i18n->openCatalog(catalog); 71 i18n->openCatalog(catalog);
71} 72}