aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/DsdLib.cxx
diff options
context:
space:
mode:
authorJoff <jauffrayl@gmail.com>2014-07-09 19:18:36 +0200
committerMax Kellermann <max@duempel.org>2014-07-09 19:18:36 +0200
commit09384df32cc6bef40bc3630de1c928d2eb424909 (patch)
tree2fe6c8683a931ac3142d0014c74e1d8102ad5f23 /src/decoder/DsdLib.cxx
parent20538516b92082067ce3477d612fb404ba8671ad (diff)
downloadmpd-09384df32cc6bef40bc3630de1c928d2eb424909.tar.gz
mpd-09384df32cc6bef40bc3630de1c928d2eb424909.tar.xz
mpd-09384df32cc6bef40bc3630de1c928d2eb424909.zip
decoder/dsd: use decoder_read_full() where appropriate
Addresses Mantis ticket 0004015. [mk: use decoder_read_full() only when needed, and a few formal changes]
Diffstat (limited to 'src/decoder/DsdLib.cxx')
-rw-r--r--src/decoder/DsdLib.cxx10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/decoder/DsdLib.cxx b/src/decoder/DsdLib.cxx
index 67cc7e945..eafedda8f 100644
--- a/src/decoder/DsdLib.cxx
+++ b/src/decoder/DsdLib.cxx
@@ -49,14 +49,6 @@ DsdId::Equals(const char *s) const
return memcmp(value, s, sizeof(value)) == 0;
}
-bool
-dsdlib_read(Decoder *decoder, InputStream &is,
- void *data, size_t length)
-{
- size_t nbytes = decoder_read(decoder, is, data, length);
- return nbytes == length;
-}
-
/**
* Skip the #input_stream to the specified offset.
*/
@@ -149,7 +141,7 @@ dsdlib_tag_id3(InputStream &is,
id3_byte_t *dsdid3data;
dsdid3data = dsdid3;
- if (!dsdlib_read(nullptr, is, dsdid3data, count))
+ if (!decoder_read_full(nullptr, is, dsdid3data, count))
return;
id3_tag = id3_tag_parse(dsdid3data, count);