X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Faudiosource.cc;h=12c12099d5a352d090ca398d42931be1afd83c9f;hb=b3ef0a9e8d4a5ed9042c0e61d5437ad99c664247;hp=9d90d05cb12ddc030fa16f67a85d353977b28347;hpb=bfe92c5b4fbc2bb263636098d45b41e3d4e38c6f;p=ardour.git diff --git a/libs/ardour/audiosource.cc b/libs/ardour/audiosource.cc index 9d90d05cb1..12c12099d5 100644 --- a/libs/ardour/audiosource.cc +++ b/libs/ardour/audiosource.cc @@ -58,7 +58,7 @@ #include "ardour/runtime_functions.h" #include "ardour/session.h" -#include "i18n.h" +#include "pbd/i18n.h" #include "ardour/debug.h" @@ -142,7 +142,7 @@ AudioSource::get_state () int AudioSource::set_state (const XMLNode& node, int /*version*/) { - const XMLProperty* prop; + XMLProperty const * prop; if ((prop = node.property ("captured-for")) != 0) { _captured_for = prop->value(); @@ -387,7 +387,9 @@ AudioSource::read_peaks_with_fpp (PeakData *peaks, framecnt_t npeaks, framepos_t if (statbuf.st_size < expected_file_size) { warning << string_compose (_("peak file %1 is truncated from %2 to %3"), _peakpath, expected_file_size, statbuf.st_size) << endmsg; + lm.release(); // build_peaks_from_scratch() takes _lock const_cast(this)->build_peaks_from_scratch (); + lm.acquire (); if (g_stat (_peakpath.c_str(), &statbuf) != 0) { error << string_compose (_("Cannot open peakfile @ %1 for size check (%2) after rebuild"), _peakpath, strerror (errno)) << endmsg; }