summaryrefslogtreecommitdiff
path: root/src/PlatformUtils.cc
diff options
context:
space:
mode:
authorDon Bright <hugh.m.bright@gmail.com>2013-05-27 03:55:14 (GMT)
committerDon Bright <hugh.m.bright@gmail.com>2013-05-27 03:55:14 (GMT)
commit6742ad55f4cf335fc767ab65784aab81e06b61d0 (patch)
tree53bf1b3661a8d0d894487d20906b26e498158649 /src/PlatformUtils.cc
parent53e778af703e40e91c2021d4ab12f8d30e14bd60 (diff)
fix buggy string init. remove debug string
Diffstat (limited to 'src/PlatformUtils.cc')
-rw-r--r--src/PlatformUtils.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/PlatformUtils.cc b/src/PlatformUtils.cc
index 47569b0..5dd007d 100644
--- a/src/PlatformUtils.cc
+++ b/src/PlatformUtils.cc
@@ -7,7 +7,7 @@ bool PlatformUtils::createLibraryPath()
bool OK = false;
try {
if (!fs::exists(fs::path(path))) {
- PRINTB("Creating library folder %s", path );
+ //PRINTB("Creating library folder %s", path );
OK = fs::create_directories( path );
}
if (!OK) {
@@ -23,11 +23,14 @@ std::string PlatformUtils::libraryPath()
{
fs::path path;
try {
- path = boosty::canonical(fs::path(PlatformUtils::documentsPath()));
+ std::string pathstr = PlatformUtils::documentsPath();
+ if (pathstr=="") return "";
+ path = boosty::canonical(fs::path( pathstr ));
+ //PRINTB("path size %i",boosty::stringy(path).size());
+ //PRINTB("lib path found: [%s]", path );
if (path.empty()) return "";
path /= "OpenSCAD";
path /= "libraries";
- //PRINTB("path size %i",boosty::stringy(path).size());
//PRINTB("Appended path %s", path );
//PRINTB("Exists: %i", fs::exists(path) );
} catch (const fs::filesystem_error& ex) {
contact: Jan Huwald // Impressum