summaryrefslogtreecommitdiff
path: root/cpp/src/Freeze/IndexI.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/Freeze/IndexI.cpp')
-rw-r--r--cpp/src/Freeze/IndexI.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/cpp/src/Freeze/IndexI.cpp b/cpp/src/Freeze/IndexI.cpp
index 3c05f862ee2..21231e707ca 100644
--- a/cpp/src/Freeze/IndexI.cpp
+++ b/cpp/src/Freeze/IndexI.cpp
@@ -12,7 +12,7 @@
#include <Freeze/ObjectStore.h>
#include <Freeze/EvictorI.h>
-#include <Ice/StringConverter.h>
+#include <IceUtil/StringConverter.h>
using namespace Freeze;
using namespace Ice;
@@ -379,13 +379,16 @@ Freeze::IndexI::associate(ObjectStoreBase* store, DbTxn* txn,
}
//
- // We keep _dbName as a native string here, while it might have
+ //
+ // Berkeley DB expects file paths to be UTF8 encoded. We keep
+ // _dbName as a native string here, while it might have
// been better to convert it to UTF-8, changing this isn't
// possible without potentially breaking backward compatibility
// with deployed databases.
//
- _db->open(txn, Ice::nativeToUTF8(store->communicator(), store->evictor()->filename()).c_str(), _dbName.c_str(),
- DB_BTREE, flags, FREEZE_DB_MODE);
+ _db->open(txn,
+ IceUtil::nativeToUTF8(IceUtil::getProcessStringConverter(), store->evictor()->filename()).c_str(),
+ _dbName.c_str(), DB_BTREE, flags, FREEZE_DB_MODE);
flags = 0;
if(populateIndex)