Skip to content

Instantly share code, notes, and snippets.

@compholio
Created March 2, 2015 18:01
Show Gist options
  • Save compholio/6c7274314ae4cade3cb7 to your computer and use it in GitHub Desktop.
Save compholio/6c7274314ae4cade3cb7 to your computer and use it in GitHub Desktop.
strmbase: Fix MediaSeekingPassThru_GetPositions return when the pins are unconnected.
From 7f801adb195ca665ee1caa3453bc76326dc759cd Mon Sep 17 00:00:00 2001
From: "Erich E. Hoover" <erich.e.hoover@wine-staging.com>
Date: Mon, 2 Mar 2015 11:01:22 -0700
Subject: strmbase: Fix MediaSeekingPassThru_GetPositions return when the pins are
unconnected.
---
dlls/strmbase/pospass.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/dlls/strmbase/pospass.c b/dlls/strmbase/pospass.c
index e547328..424853a 100644
--- a/dlls/strmbase/pospass.c
+++ b/dlls/strmbase/pospass.c
@@ -526,9 +526,11 @@ static HRESULT WINAPI MediaSeekingPassThru_GetPositions(IMediaSeeking * iface, L
if (SUCCEEDED(hr)) {
hr = IMediaSeeking_GetPositions(seek, pCurrent, pStop);
IMediaSeeking_Release(seek);
+ } else if (hr == VFW_E_NOT_CONNECTED) {
+ *pCurrent = 0;
+ *pStop = 0;
+ hr = S_OK;
}
- else
- return E_NOTIMPL;
return hr;
}
--
1.9.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment