aboutsummaryrefslogtreecommitdiffstats
path: root/src/playerData.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-04-12 04:13:24 +0000
committerEric Wong <normalperson@yhbt.net>2008-04-12 04:13:24 +0000
commit74910df0f367143e73e460524b31bacead953b16 (patch)
tree571196ade2bc01216679b5181b72d7e754a1f48a /src/playerData.c
parent68a625b5b819416dacf2e4def6e124413d5226c5 (diff)
downloadmpd-74910df0f367143e73e460524b31bacead953b16.tar.gz
mpd-74910df0f367143e73e460524b31bacead953b16.tar.xz
mpd-74910df0f367143e73e460524b31bacead953b16.zip
added struct OutputBufferChunk
To make access to OutputBuffer easier, move everything which belongs to a chunk into its own structure, namely OutputBufferChunk. git-svn-id: https://svn.musicpd.org/mpd/trunk@7269 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r--src/playerData.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/playerData.c b/src/playerData.c
index 718b28771..f9cc314a9 100644
--- a/src/playerData.c
+++ b/src/playerData.c
@@ -74,7 +74,7 @@ void initPlayerData(void)
buffered_before_play = buffered_chunks;
}
- allocationSize = buffered_chunks * CHUNK_SIZE; /*actual buffer */
+ allocationSize = buffered_chunks * sizeof(OutputBufferChunk); /*actual buffer */
allocationSize += buffered_chunks * sizeof(float); /*for times */
allocationSize += buffered_chunks * sizeof(mpd_sint16); /*for chunkSize */
allocationSize += buffered_chunks * sizeof(mpd_sint16); /*for bitRate */
@@ -94,7 +94,7 @@ void initPlayerData(void)
allocationSize - device_array_size;
initOutputBuffer(&(playerData_pd->buffer),
- ((char *)playerData_pd) + sizeof(PlayerData));
+ (OutputBufferChunk*)(((char *)playerData_pd) + sizeof(PlayerData)));
playerData_pd->playerControl.stop = 0;
playerData_pd->playerControl.pause = 0;