waveout: Fix compile warnings

* Include pulse/util.h for pa_thread_make_realtime.
* Explicitly cast HWAVEOUT to UINT_PTR for waveOutGetDevCaps.

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/457>
This commit is contained in:
Patrick Gaskin 2021-01-03 04:04:52 -05:00 committed by PulseAudio Marge Bot
parent 7fc021f5d0
commit eb1297f124

View file

@ -28,6 +28,7 @@
#include <pulse/xmalloc.h>
#include <pulse/timeval.h>
#include <pulse/util.h>
#include <pulsecore/sink.h>
#include <pulsecore/source.h>
@ -412,7 +413,7 @@ static void sink_get_volume_cb(pa_sink *s) {
DWORD vol;
pa_volume_t left, right;
if (waveOutGetDevCaps(u->hwo, &caps, sizeof(caps)) != MMSYSERR_NOERROR)
if (waveOutGetDevCaps((UINT_PTR) u->hwo, &caps, sizeof(caps)) != MMSYSERR_NOERROR)
return;
if (!(caps.dwSupport & WAVECAPS_VOLUME))
return;
@ -440,7 +441,7 @@ static void sink_set_volume_cb(pa_sink *s) {
WAVEOUTCAPS caps;
DWORD vol;
if (waveOutGetDevCaps(u->hwo, &caps, sizeof(caps)) != MMSYSERR_NOERROR)
if (waveOutGetDevCaps((UINT_PTR) u->hwo, &caps, sizeof(caps)) != MMSYSERR_NOERROR)
return;
if (!(caps.dwSupport & WAVECAPS_VOLUME))
return;