summaryrefslogtreecommitdiffstats
path: root/src/modules/UserConfigBackendHome
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/UserConfigBackendHome')
-rw-r--r--src/modules/UserConfigBackendHome/UserConfigBackendHome.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/modules/UserConfigBackendHome/UserConfigBackendHome.cpp b/src/modules/UserConfigBackendHome/UserConfigBackendHome.cpp
index e1db3b9..4dca729 100644
--- a/src/modules/UserConfigBackendHome/UserConfigBackendHome.cpp
+++ b/src/modules/UserConfigBackendHome/UserConfigBackendHome.cpp
@@ -48,9 +48,9 @@ bool UserConfigBackendHome::handleConfigEntry(const Core::ConfigEntry &entry, bo
}
else {
char *endptr;
- unsigned long val = std::strtoul(entry[1][0].extract().c_str(), &endptr, 8);
+ unsigned long val = std::strtoul(entry[1][0].toString().c_str(), &endptr, 8);
if(*endptr || val > 07777) {
- application->logf(Core::Logger::LOG_WARNING, "UserBackendHome: Invalid configuration: DirMode '%s'", entry[1][0].extract().c_str());
+ application->logf(Core::Logger::LOG_WARNING, "UserBackendHome: Invalid configuration: DirMode '%s'", entry[1][0].toLocale().c_str());
}
else {
dirMode = val;
@@ -104,8 +104,8 @@ void UserConfigBackendHome::migrateOwner(const std::string &path, const Common::
}
void UserConfigBackendHome::addUser(const Common::UserInfo &userInfo) throw(Core::Exception) {
- boost::filesystem::path path(homeDir.extract());
- path /= userInfo.getUsername().extract();
+ boost::filesystem::path path(homeDir.toLocale());
+ path /= userInfo.getUsername().toLocale();
boost::filesystem::create_directories(path);
@@ -118,7 +118,7 @@ void UserConfigBackendHome::addUser(const Common::UserInfo &userInfo) throw(Core
// TODO Error
}
- boost::filesystem::path skeletonPath(skeleton.extract());
+ boost::filesystem::path skeletonPath(skeleton.toLocale());
if(!boost::filesystem::is_directory(skeletonPath))
return;
@@ -161,11 +161,11 @@ void UserConfigBackendHome::addUser(const Common::UserInfo &userInfo) throw(Core
}
void UserConfigBackendHome::updateUser(const Common::UserInfo &oldUserInfo, const Common::UserInfo &userInfo) throw(Core::Exception) {
- boost::filesystem::path oldPath(homeDir.extract());
- oldPath /= oldUserInfo.getUsername().extract();
+ boost::filesystem::path oldPath(homeDir.toLocale());
+ oldPath /= oldUserInfo.getUsername().toLocale();
- boost::filesystem::path path(homeDir.extract());
- path /= userInfo.getUsername().extract();
+ boost::filesystem::path path(homeDir.toLocale());
+ path /= userInfo.getUsername().toLocale();
if(oldPath != path) {
try {
@@ -202,8 +202,8 @@ void UserConfigBackendHome::updateUser(const Common::UserInfo &oldUserInfo, cons
}
void UserConfigBackendHome::deleteUser(const Common::UserInfo &userInfo) throw(Core::Exception) {
- boost::filesystem::path path(homeDir.extract());
- path /= userInfo.getUsername().extract();
+ boost::filesystem::path path(homeDir.toLocale());
+ path /= userInfo.getUsername().toLocale();
boost::filesystem::remove_all(path);
}