SDL: wasapi: Fixed incorrect assertions. (40698)

From 40698ee33c7f5596f0bdea6ae0d13ad747cf0297 Mon Sep 17 00:00:00 2001
From: "Ryan C. Gordon" <[EMAIL REDACTED]>
Date: Mon, 12 Dec 2022 16:07:48 -0500
Subject: [PATCH] wasapi: Fixed incorrect assertions.

Fixes #6795.
(cherry-picked from commit 12486e144be0e7a37abd87b8bf90547a992ff66b)
---
 src/audio/wasapi/SDL_wasapi_winrt.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/audio/wasapi/SDL_wasapi_winrt.cpp b/src/audio/wasapi/SDL_wasapi_winrt.cpp
index 235ae7d32eb4..43bf130eb741 100644
--- a/src/audio/wasapi/SDL_wasapi_winrt.cpp
+++ b/src/audio/wasapi/SDL_wasapi_winrt.cpp
@@ -189,14 +189,14 @@ SDL_WasapiDeviceEventHandler::OnEnumerationCompleted(DeviceWatcher^ sender, Plat
 void
 SDL_WasapiDeviceEventHandler::OnDefaultRenderDeviceChanged(Platform::Object^ sender, DefaultAudioRenderDeviceChangedEventArgs^ args)
 {
-    SDL_assert(this->iscapture);
+    SDL_assert(!this->iscapture);
     SDL_AtomicAdd(&SDL_IMMDevice_DefaultPlaybackGeneration, 1);
 }
 
 void
 SDL_WasapiDeviceEventHandler::OnDefaultCaptureDeviceChanged(Platform::Object^ sender, DefaultAudioCaptureDeviceChangedEventArgs^ args)
 {
-    SDL_assert(!this->iscapture);
+    SDL_assert(this->iscapture);
     SDL_AtomicAdd(&SDL_IMMDevice_DefaultCaptureGeneration, 1);
 }