From a4f0c7b457a5806568097f88730433dc7bc19f00 Mon Sep 17 00:00:00 2001 From: Emanuele Giaquinta Date: Wed, 17 Dec 2008 15:48:12 +0100 Subject: [PATCH] Use MIN. --- src/output/osx_plugin.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/output/osx_plugin.c b/src/output/osx_plugin.c index 1087ddb2d..d1d65ae00 100644 --- a/src/output/osx_plugin.c +++ b/src/output/osx_plugin.c @@ -181,7 +181,7 @@ osx_render(void *vdata, } */ - bytesToCopy = od->len < bufferSize ? od->len : bufferSize; + bytesToCopy = MIN(od->len, bufferSize); bufferSize = bytesToCopy; od->len -= bytesToCopy; @@ -321,7 +321,7 @@ osx_play(void *data, const char *playChunk, size_t size) if (curpos >= od->bufferSize) curpos -= od->bufferSize; - bytesToCopy = od->bufferSize < size ? od->bufferSize : size; + bytesToCopy = MIN(od->bufferSize, size); while (od->len > od->bufferSize - bytesToCopy) { /* DEBUG("osx_play: wait\n"); */