summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swiften/Application/Unix')
-rw-r--r--Swiften/Application/Unix/UnixApplication.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/Swiften/Application/Unix/UnixApplication.h b/Swiften/Application/Unix/UnixApplication.h
index 1c985e8..56ee0ed 100644
--- a/Swiften/Application/Unix/UnixApplication.h
+++ b/Swiften/Application/Unix/UnixApplication.h
@@ -10,6 +10,8 @@
#include "Swiften/Application/Application.h"
#include "Swiften/Application/NullApplicationMessageDisplay.h"
+#include <iostream>
+
namespace Swift {
class UnixApplication : public Application {
public:
@@ -26,7 +28,12 @@ namespace Swift {
boost::filesystem::path getSettingsDir() const {
boost::filesystem::path result(getHomeDir() / ("." + getName().getLowerCase().getUTF8String()));
- boost::filesystem::create_directory(result);
+ try {
+ boost::filesystem::create_directory(result);
+ }
+ catch (const boost::filesystem::filesystem_error& e) {
+ std::cerr << "ERROR: " << e.what() << std::endl;
+ }
return result;
}