wine-staging/patches/06-winepulse/0010-winepulse-v12.patch

49 lines
1.6 KiB
Diff

From 99756a89f015bdf24d42ef75b59736d2cfd930c5 Mon Sep 17 00:00:00 2001
From: Maarten Lankhorst <m.b.lankhorst@gmail.com>
Date: Tue, 24 Jun 2014 08:48:46 +0200
Subject: [PATCH 17/43] winepulse v12
Changes since v11:
- Fix incorrect assertions which may fail on moving a capture device
- Whitespace apply fixes
Changes since v10:
- Make some members static
- Fix small memory leak in GetService
---
dlls/winepulse.drv/mmdevdrv.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/winepulse.drv/mmdevdrv.c b/dlls/winepulse.drv/mmdevdrv.c
index 5a71a3d..960af3c 100644
--- a/dlls/winepulse.drv/mmdevdrv.c
+++ b/dlls/winepulse.drv/mmdevdrv.c
@@ -596,10 +596,11 @@ static void pulse_rd_loop(ACImpl *This, size_t bytes)
dst = p->data;
while (rem) {
pa_stream_peek(This->stream, (const void**)&src, &src_len);
- assert(src_len && src_len <= bytes);
+ assert(src_len);
assert(This->peek_ofs < src_len);
src += This->peek_ofs;
src_len -= This->peek_ofs;
+ assert(src_len <= bytes);
copy = rem;
if (copy > src_len)
@@ -627,9 +628,10 @@ static void pulse_rd_drop(ACImpl *This, size_t bytes)
while (rem) {
const void *src;
pa_stream_peek(This->stream, &src, &src_len);
- assert(src_len && src_len <= bytes);
+ assert(src_len);
assert(This->peek_ofs < src_len);
src_len -= This->peek_ofs;
+ assert(src_len <= bytes);
copy = rem;
if (copy > src_len)
--
2.0.0