mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-08 07:45:00 +01:00
Fix the URI handling (for sfdb) for Windows
This forward ports Mixbus' 4eca3dea47 without additional code to correct for old (Ardour2) URIs. A2, used path2uri() which accumulated and left duplicate slashes in place, eg. "file:////". Mixbus3 auto-corrected this on load in AudioLibrary::search_members_and(). However sfdb libraries are not shared between major versions, so this code does no need to be forward ported.
This commit is contained in:
parent
6cfb164d7c
commit
c218b65d24
1 changed files with 7 additions and 2 deletions
|
|
@ -78,8 +78,13 @@ void
|
||||||
AudioLibrary::save_changes ()
|
AudioLibrary::save_changes ()
|
||||||
{
|
{
|
||||||
#ifdef HAVE_LRDF
|
#ifdef HAVE_LRDF
|
||||||
if (lrdf_export_by_source(src.c_str(), src.substr(5).c_str())) {
|
#ifdef PLATFORM_WINDOWS
|
||||||
PBD::warning << string_compose(_("Could not open %1. Audio Library not saved"), src) << endmsg;
|
string path = Glib::locale_from_utf8 (Glib::filename_from_uri(src));
|
||||||
|
#else
|
||||||
|
string path = Glib::filename_from_uri(src);
|
||||||
|
#endif
|
||||||
|
if (lrdf_export_by_source(src.c_str(), path.c_str())) {
|
||||||
|
PBD::warning << string_compose(_("Could not open %1. Audio Library not saved"), path) << endmsg;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue