13
0

Replace use of pbd/filesystem.h with Glib equivalent in Mootcher class

git-svn-id: svn://localhost/ardour2/branches/3.0@12886 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Tim Mayberry 2012-06-23 05:09:08 +00:00
parent af0083b11d
commit 6b62959ba0

View File

@ -41,7 +41,7 @@
#include "sfdb_freesound_mootcher.h"
#include "pbd/xml++.h"
#include "pbd/filesystem.h"
#include "pbd/error.h"
#include <sys/stat.h>
#include <sys/types.h>
@ -91,10 +91,12 @@ void Mootcher::changeWorkingDir(const char *saveLocation)
void Mootcher::ensureWorkingDir ()
{
PBD::sys::path p = basePath;
p /= "snd";
if (!PBD::sys::is_directory (p)) {
PBD::sys::create_directories (p);
std::string p = Glib::build_filename (basePath, "snd");
if (!Glib::file_test (p, Glib::FILE_TEST_IS_DIR)) {
if (g_mkdir_with_parents (p.c_str(), 0775) != 0) {
PBD::error << "Unable to create Mootcher working dir" << endmsg;
}
}
}