[beast/devel: 19/28] FLAC: fix compiler warnings, remove extra whitespace
- From: Tim Janik <timj src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [beast/devel: 19/28] FLAC: fix compiler warnings, remove extra whitespace
- Date: Sat, 4 May 2013 03:53:49 +0000 (UTC)
commit 60d180cd70ff6e8a1baffdfe647803ecc9475185
Author: Stefan Westerfeld <stefan space twc de>
Date: Sat Mar 23 16:16:41 2013 +0100
FLAC: fix compiler warnings, remove extra whitespace
bse/bsedatahandle-flac.cc | 4 ++--
bse/bseloader-flac.cc | 5 +++--
2 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/bse/bsedatahandle-flac.cc b/bse/bsedatahandle-flac.cc
index 1a2d8b9..0c9db56 100644
--- a/bse/bsedatahandle-flac.cc
+++ b/bse/bsedatahandle-flac.cc
@@ -257,7 +257,7 @@ public:
int64 n_values,
float *values)
{
- if (voffset >= m_buffer_start + m_buffer.size())
+ if (voffset >= m_buffer_start + (int64) m_buffer.size())
{
// try to read on, probably we'll have just the samples we need, then
m_error_occurred = false;
@@ -267,7 +267,7 @@ public:
return -1;
}
- if (voffset >= m_buffer_start && voffset < m_buffer_start + m_buffer.size())
+ if (voffset >= m_buffer_start && voffset < m_buffer_start + (int64) m_buffer.size())
{
int64 buffer_offset = voffset - m_buffer_start;
n_values = MIN (n_values, m_buffer.size() - buffer_offset);
diff --git a/bse/bseloader-flac.cc b/bse/bseloader-flac.cc
index dff0fba..4729b76 100644
--- a/bse/bseloader-flac.cc
+++ b/bse/bseloader-flac.cc
@@ -54,9 +54,10 @@ struct FileInfo
}
/* decode enough to figure out channel count */
+ FLAC__bool mdok;
do {
- FLAC__bool mdok = FLAC__stream_decoder_process_single (decoder);
- } while (FLAC__stream_decoder_get_channels (decoder) == 0);
+ mdok = FLAC__stream_decoder_process_single (decoder);
+ } while (FLAC__stream_decoder_get_channels (decoder) == 0 && mdok);
/* allocate and fill BseWaveFileInfo */
wfi.n_waves = 1;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]