From 0891a0e5ebf439776004bb99f33e2982d404ccc5 Mon Sep 17 00:00:00 2001 From: Edward Hervey Date: Thu, 9 Jan 2025 11:39:11 +0100 Subject: [PATCH] wasapi: Use signed value for can_frames The can retrieval function can return negative values (which will be properly handled) Part-of: --- subprojects/gst-plugins-bad/sys/wasapi/gstwasapisink.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/subprojects/gst-plugins-bad/sys/wasapi/gstwasapisink.c b/subprojects/gst-plugins-bad/sys/wasapi/gstwasapisink.c index b5005fc72c..ca8ad2fbc8 100644 --- a/subprojects/gst-plugins-bad/sys/wasapi/gstwasapisink.c +++ b/subprojects/gst-plugins-bad/sys/wasapi/gstwasapisink.c @@ -616,7 +616,8 @@ gst_wasapi_sink_write (GstAudioSink * asink, gpointer data, guint length) HRESULT hr; gint16 *dst = NULL; DWORD dwWaitResult; - guint can_frames, have_frames, n_frames, write_len, written_len = 0; + gint can_frames; + guint have_frames, n_frames, write_len, written_len = 0; HANDLE event_handle[2]; event_handle[0] = self->event_handle;