summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
Diffstat (limited to 'libs')
-rw-r--r--libs/ardouralsautil/deviceparams.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/libs/ardouralsautil/deviceparams.cc b/libs/ardouralsautil/deviceparams.cc
index 613eac76e0..05e51201ef 100644
--- a/libs/ardouralsautil/deviceparams.cc
+++ b/libs/ardouralsautil/deviceparams.cc
@@ -103,6 +103,9 @@ ARDOUR::get_alsa_device_parameters (const char* device_name, const bool play, AL
snd_pcm_close (pcm);
+ nfo->min_size = std::max (min_psiz, min_bufz / nfo->max_nper);
+ nfo->max_size = std::min (max_psiz, max_bufz / nfo->min_nper);
+
/* see also libs/backends/alsa/zita-alsa-pcmi.cc
* If any debug parameter is set, print device info.
*/
@@ -121,8 +124,6 @@ ARDOUR::get_alsa_device_parameters (const char* device_name, const bool play, AL
fprintf (stdout, " possible : %lu .. %lu\n", nfo->min_size, nfo->max_size);
}
- nfo->min_size = std::max (min_psiz, min_bufz / nfo->max_nper);
- nfo->max_size = std::min (max_psiz, max_bufz / nfo->min_nper);
nfo->valid = true;
return 0;