summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gtk2_ardour/sfdb_freesound_mootcher.cc17
-rw-r--r--gtk2_ardour/sfdb_freesound_mootcher.h1
2 files changed, 7 insertions, 11 deletions
diff --git a/gtk2_ardour/sfdb_freesound_mootcher.cc b/gtk2_ardour/sfdb_freesound_mootcher.cc
index 484df19941..ba9b4052c8 100644
--- a/gtk2_ardour/sfdb_freesound_mootcher.cc
+++ b/gtk2_ardour/sfdb_freesound_mootcher.cc
@@ -75,17 +75,14 @@ const char* Mootcher::changeWorkingDir(const char *saveLocation)
//
int pos2 = basePath.find_last_of("/");
if(basePath.length() != (pos2+1)) basePath += "/";
- // add a check if the given directory exists
- createResourceLocation();
- return basePath.c_str();
-}
+
+ // create Freesound directory and sound dir
+ std::string sndLocation = basePath;
+ mkdir(sndLocation.c_str(), 0x777);
+ sndLocation += "snd";
+ mkdir(sndLocation.c_str(), 0x777);
-//------------------------------------------------------------------------
-void Mootcher::createResourceLocation()
-{
- // create a snd directory
- std::string sndLocation = basePath + "snd";
- mkdir(sndLocation.c_str(), 0x777);
+ return basePath.c_str();
}
//------------------------------------------------------------------------
diff --git a/gtk2_ardour/sfdb_freesound_mootcher.h b/gtk2_ardour/sfdb_freesound_mootcher.h
index af5f4e0bab..3cfbd414d4 100644
--- a/gtk2_ardour/sfdb_freesound_mootcher.h
+++ b/gtk2_ardour/sfdb_freesound_mootcher.h
@@ -55,7 +55,6 @@ public:
private:
const char* changeWorkingDir(const char *saveLocation);
- void createResourceLocation();
std::string getXmlFile(std::string ID, int &length);
void GetXml(std::string ID, struct MemoryStruct &xml_page);