Zebediah Figura : winegstreamer: Use IMemAllocator::GetBuffer() directly.
Alexandre Julliard
julliard at winehq.org
Mon Feb 7 15:56:03 CST 2022
Module: wine
Branch: master
Commit: 8c7ad5fc397e4814c33fa4b85be505db94d70016
URL: https://source.winehq.org/git/wine.git/?a=commit;h=8c7ad5fc397e4814c33fa4b85be505db94d70016
Author: Zebediah Figura <zfigura at codeweavers.com>
Date: Sun Feb 6 20:59:39 2022 -0600
winegstreamer: Use IMemAllocator::GetBuffer() directly.
BaseOutputPinImpl_GetDeliveryBuffer() is doing nothing helpful here. Note that
we cannot be unconnected at this point, or stream_thread() would not even be
running.
Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/winegstreamer/quartz_parser.c | 14 ++++----------
1 file changed, 4 insertions(+), 10 deletions(-)
diff --git a/dlls/winegstreamer/quartz_parser.c b/dlls/winegstreamer/quartz_parser.c
index 331bc9a888a..45313ebda27 100644
--- a/dlls/winegstreamer/quartz_parser.c
+++ b/dlls/winegstreamer/quartz_parser.c
@@ -753,12 +753,9 @@ static void send_buffer(struct parser_source *pin, const struct wg_parser_event
{
uint32_t advance;
- hr = BaseOutputPinImpl_GetDeliveryBuffer(&pin->pin, &sample, NULL, NULL, 0);
-
- if (FAILED(hr))
+ if (FAILED(hr = IMemAllocator_GetBuffer(pin->pin.pAllocator, &sample, NULL, NULL, 0)))
{
- if (hr != VFW_E_NOT_CONNECTED)
- ERR("Failed to get a sample, hr %#lx.\n", hr);
+ ERR("Failed to get a sample, hr %#lx.\n", hr);
break;
}
@@ -776,12 +773,9 @@ static void send_buffer(struct parser_source *pin, const struct wg_parser_event
}
else
{
- hr = BaseOutputPinImpl_GetDeliveryBuffer(&pin->pin, &sample, NULL, NULL, 0);
-
- if (FAILED(hr))
+ if (FAILED(hr = IMemAllocator_GetBuffer(pin->pin.pAllocator, &sample, NULL, NULL, 0)))
{
- if (hr != VFW_E_NOT_CONNECTED)
- ERR("Failed to get a sample, hr %#lx.\n", hr);
+ ERR("Failed to get a sample, hr %#lx.\n", hr);
}
else
{
More information about the wine-cvs
mailing list