#include <msp/core/application.h>
+#include <msp/core/environ.h>
#include "dir.h"
using namespace std;
if(len)
return string(buf, len);
- const char *home = getenv("HOME");
- if(home)
+ string home = getenv("HOME");
+ if(!home.empty())
return home;
return ".";
}
-Path get_user_data_dir(const string &)
-{
- return get_user_data_dir();
-}
-
Path get_user_data_dir()
{
const string &appname = Application::get_name();