summaryrefslogtreecommitdiff
path: root/apps/codecs/flac.c
diff options
context:
space:
mode:
authorBrandon Low <lostlogic@rockbox.org>2006-03-24 13:43:15 +0000
committerBrandon Low <lostlogic@rockbox.org>2006-03-24 13:43:15 +0000
commit86f1e2ead283d86f6896ca0f98c0b711da5e2cfe (patch)
treefe961ef2fdfe8a5d6317604246acf63440326435 /apps/codecs/flac.c
parentb1cd32913dcd9bba7960c1f8f3b384ee1ff5a259 (diff)
downloadrockbox-86f1e2ead283d86f6896ca0f98c0b711da5e2cfe.tar.gz
rockbox-86f1e2ead283d86f6896ca0f98c0b711da5e2cfe.zip
Convert playback.c to use unsigned byte counters, and _minor_ refactoring of buffer callbacks
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9227 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs/flac.c')
-rw-r--r--apps/codecs/flac.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/apps/codecs/flac.c b/apps/codecs/flac.c
index fa263c1095..f95ae2a8ce 100644
--- a/apps/codecs/flac.c
+++ b/apps/codecs/flac.c
@@ -118,11 +118,9 @@ static bool flac_init(FLACContext* fc, int first_frame_offset)
118 118
119 if ((buf[0] & 0x7f) == 0) /* 0 is the STREAMINFO block */ 119 if ((buf[0] & 0x7f) == 0) /* 0 is the STREAMINFO block */
120 { 120 {
121 /* FIXME: Don't trust the value of blocklength */ 121 /* FIXME: Don't trust the value of blocklength, use actual return
122 if (ci->read_filebuf(buf, blocklength) < 0) 122 * value in bytes instead */
123 { 123 ci->read_filebuf(buf, blocklength);
124 return false;
125 }
126 124
127 fc->filesize = ci->filesize; 125 fc->filesize = ci->filesize;
128 fc->min_blocksize = (buf[0] << 8) | buf[1]; 126 fc->min_blocksize = (buf[0] << 8) | buf[1];