summaryrefslogtreecommitdiff
path: root/src/input
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2019-01-20 22:02:24 +0100
committerMax Kellermann <max@musicpd.org>2019-01-20 22:03:49 +0100
commitc7848da8f2872f26d10410e8817a37024bf6bfa1 (patch)
tree49ffa0012df3f010d05b7733643d8dee895b06fa /src/input
parent10a6c5c57d0fa04c55fdd40f260af557b024cc39 (diff)
input/CdioParanoia: add `const` to pointer
Diffstat (limited to 'src/input')
-rw-r--r--src/input/plugins/CdioParanoiaInputPlugin.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/input/plugins/CdioParanoiaInputPlugin.cxx b/src/input/plugins/CdioParanoiaInputPlugin.cxx
index 00b637686..93fe19e47 100644
--- a/src/input/plugins/CdioParanoiaInputPlugin.cxx
+++ b/src/input/plugins/CdioParanoiaInputPlugin.cxx
@@ -293,7 +293,7 @@ CdioParanoiaInputStream::Read(void *ptr, size_t length)
break;
//current sector was changed ?
- int16_t *rbuf;
+ const int16_t *rbuf;
if (lsn_relofs != buffer_lsn) {
const ScopeUnlock unlock(mutex);
@@ -317,7 +317,7 @@ CdioParanoiaInputStream::Read(void *ptr, size_t length)
buffer_lsn = lsn_relofs;
} else {
//use cached sector
- rbuf = (int16_t *)buffer;
+ rbuf = (const int16_t *)buffer;
}
//correct offset
@@ -329,7 +329,7 @@ CdioParanoiaInputStream::Read(void *ptr, size_t length)
const size_t len = (length < maxwrite? length : maxwrite);
//skip diff bytes from this lsn
- memcpy(wptr, ((char*)rbuf) + diff, len);
+ memcpy(wptr, ((const char *)rbuf) + diff, len);
//update pointer
wptr += len;
nbytes += len;