diff options
author | Paul Adenot <[email protected]> | 2023-04-24 14:15:22 +0200 |
---|---|---|
committer | Paul Adenot <[email protected]> | 2023-04-26 14:28:46 +0200 |
commit | af5e9f1211f0be823c8c71bc154c7b9ac3b332d4 (patch) | |
tree | a131a8545770d3ef1b0aa992012e5b67a04e9b99 | |
parent | 31fb25d7eb232ff6281c78cc0c215572ab71a6c5 (diff) | |
download | cubeb-af5e9f1211f0be823c8c71bc154c7b9ac3b332d4.tar.gz cubeb-af5e9f1211f0be823c8c71bc154c7b9ac3b332d4.zip |
Add some logging messages to winmm to ease debugging and make the logging test pass
-rw-r--r-- | src/cubeb_winmm.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/cubeb_winmm.c b/src/cubeb_winmm.c index 793ac71..84ebbaa 100644 --- a/src/cubeb_winmm.c +++ b/src/cubeb_winmm.c @@ -167,6 +167,8 @@ winmm_refill_stream(cubeb_stream * stm) long wanted; MMRESULT r; + ALOG("winmm_refill_stream"); + EnterCriticalSection(&stm->lock); stm->free_buffers += 1; XASSERT(stm->free_buffers > 0 && stm->free_buffers <= NBUFS); @@ -174,6 +176,7 @@ winmm_refill_stream(cubeb_stream * stm) if (stm->draining) { LeaveCriticalSection(&stm->lock); if (stm->free_buffers == NBUFS) { + ALOG("winmm_refill_stream draining"); stm->state_callback(stm, stm->user_ptr, CUBEB_STATE_DRAINED); } SetEvent(stm->event); @@ -232,6 +235,8 @@ winmm_refill_stream(cubeb_stream * stm) return; } + ALOG("winmm_refill_stream %ld frames", got); + LeaveCriticalSection(&stm->lock); } @@ -575,6 +580,8 @@ winmm_stream_init(cubeb * context, cubeb_stream ** stream, *stream = stm; + LOG("winmm_stream_init OK"); + return CUBEB_OK; } |