diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2015-01-29 18:56:21 -0500 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2015-01-29 21:59:55 -0500 |
commit | de8a8272bc0de7bab35aab75a6ba515d0c6c722b (patch) | |
tree | 0dc2107681dde72b5ecb68eded857b5010d1ba32 /libs/ardour/sndfile_helpers.cc | |
parent | 070818f8843b9c32da2710664de93e68e11fb4b3 (diff) |
fix incorrect return value from sndfile_data_width()
Diffstat (limited to 'libs/ardour/sndfile_helpers.cc')
-rw-r--r-- | libs/ardour/sndfile_helpers.cc | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/libs/ardour/sndfile_helpers.cc b/libs/ardour/sndfile_helpers.cc index e3e80b48e5..6a3ce248bc 100644 --- a/libs/ardour/sndfile_helpers.cc +++ b/libs/ardour/sndfile_helpers.cc @@ -123,19 +123,19 @@ sndfile_data_width (int format) int tval = format & 0xf; switch (tval) { - case SF_FORMAT_PCM_S8: - case SF_FORMAT_PCM_U8: + case SF_FORMAT_PCM_S8: + case SF_FORMAT_PCM_U8: return 8; - case SF_FORMAT_PCM_16: + case SF_FORMAT_PCM_16: return 16; - case SF_FORMAT_PCM_24: + case SF_FORMAT_PCM_24: return 24; - case SF_FORMAT_PCM_32: + case SF_FORMAT_PCM_32: return 32; - case SF_FORMAT_FLOAT: - return 1; // heh, heh - default: - // we don't handle anything else within ardour + case SF_FORMAT_FLOAT: + return 32; + default: + // we don't handle anything else within ardour return 0; } } |