diff options
Diffstat (limited to 'libs/ardour/sndfilesource.cc')
-rw-r--r-- | libs/ardour/sndfilesource.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libs/ardour/sndfilesource.cc b/libs/ardour/sndfilesource.cc index 7dc2803a65..8df88a2732 100644 --- a/libs/ardour/sndfilesource.cc +++ b/libs/ardour/sndfilesource.cc @@ -937,6 +937,10 @@ SndFileSource::get_soundfile_info (const string& path, SoundFileInfo& info, stri sf_info.format = 0; // libsndfile says to clear this before sf_open(). + if (path.empty() || Glib::file_test(path, Glib::FILE_TEST_IS_DIR)) { + return false; + } + #ifdef PLATFORM_WINDOWS int fd = g_open (path.c_str(), O_RDONLY, 0444); #else |