summaryrefslogtreecommitdiff
path: root/apps/plugin.c
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2007-04-21 18:38:25 +0000
committerMichael Sevakis <jethead71@rockbox.org>2007-04-21 18:38:25 +0000
commit26d242ae654cc1e69c55ecd49fc3a5c13dfb8052 (patch)
tree7d6881c233ba4a39bd496faa860f4baa3cc1c93f /apps/plugin.c
parentcf6f4cf6f1ef266f6df102ab4fc533b929790b19 (diff)
downloadrockbox-26d242ae654cc1e69c55ecd49fc3a5c13dfb8052.zip
rockbox-26d242ae654cc1e69c55ecd49fc3a5c13dfb8052.tar.gz
rockbox-26d242ae654cc1e69c55ecd49fc3a5c13dfb8052.tar.bz2
rockbox-26d242ae654cc1e69c55ecd49fc3a5c13dfb8052.tar.xz
General housekeeping: Make plugin buffer functions take size_t * instead of int * to match the parameter type of the buffer functions called in the core. Get rid of unsafe int * <==> size_t * casting. Use ssize_t where int was used and size_t where unsigned int was used in the buffer calls to not alter signedness in the plugins. No API version change since it should only be an issue for 64-bit sim builds.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13233 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugin.c')
-rw-r--r--apps/plugin.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/plugin.c b/apps/plugin.c
index a059a8d..0ce214c 100644
--- a/apps/plugin.c
+++ b/apps/plugin.c
@@ -667,7 +667,7 @@ int plugin_load(const char* plugin, void* parameter)
/* Returns a pointer to the portion of the plugin buffer that is not already
being used. If no plugin is loaded, returns the entire plugin buffer */
-void* plugin_get_buffer(int* buffer_size)
+void* plugin_get_buffer(size_t *buffer_size)
{
int buffer_pos;
@@ -692,10 +692,10 @@ void* plugin_get_buffer(int* buffer_size)
Playback gets stopped, to avoid conflicts.
Talk buffer is stolen as well.
*/
-void* plugin_get_audio_buffer(int* buffer_size)
+void* plugin_get_audio_buffer(size_t *buffer_size)
{
#if CONFIG_CODEC == SWCODEC
- return audio_get_buffer(true, (size_t *)buffer_size);
+ return audio_get_buffer(true, buffer_size);
#else
audio_stop();
talk_buffer_steal(); /* we use the mp3 buffer, need to tell */