Commit a4f0c7b4 authored by Emanuele Giaquinta's avatar Emanuele Giaquinta Committed by Max Kellermann

Use MIN.

parent df80ae86
......@@ -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"); */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment