Zebediah Figura : winegstreamer: Don't force event_src() onto a Wine thread.

Alexandre Julliard julliard at winehq.org
Tue Jan 26 15:54:06 CST 2021


Module: wine
Branch: master
Commit: 1655dd4593d8be39d9f4058d157c6c682903a33a
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=1655dd4593d8be39d9f4058d157c6c682903a33a

Author: Zebediah Figura <z.figura12 at gmail.com>
Date:   Mon Jan 25 23:29:05 2021 -0600

winegstreamer: Don't force event_src() onto a Wine thread.

Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/winegstreamer/gst_cbs.c  | 13 -------------
 dlls/winegstreamer/gst_cbs.h  |  2 --
 dlls/winegstreamer/gstdemux.c |  8 +-------
 3 files changed, 1 insertion(+), 22 deletions(-)

diff --git a/dlls/winegstreamer/gst_cbs.c b/dlls/winegstreamer/gst_cbs.c
index ce7c0de4e1a..4b22c445798 100644
--- a/dlls/winegstreamer/gst_cbs.c
+++ b/dlls/winegstreamer/gst_cbs.c
@@ -190,19 +190,6 @@ GstFlowReturn request_buffer_src_wrapper(GstPad *pad, GstObject *parent, guint64
     return cbdata.u.getrange_data.ret;
 }
 
-gboolean event_src_wrapper(GstPad *pad, GstObject *parent, GstEvent *event)
-{
-    struct cb_data cbdata = { EVENT_SRC };
-
-    cbdata.u.event_src_data.pad = pad;
-    cbdata.u.event_src_data.parent = parent;
-    cbdata.u.event_src_data.event = event;
-
-    call_cb(&cbdata);
-
-    return cbdata.u.event_src_data.ret;
-}
-
 void removed_decoded_pad_wrapper(GstElement *bin, GstPad *pad, gpointer user)
 {
     struct cb_data cbdata = { REMOVED_DECODED_PAD };
diff --git a/dlls/winegstreamer/gst_cbs.h b/dlls/winegstreamer/gst_cbs.h
index 29aa2bd662c..c7c559c664c 100644
--- a/dlls/winegstreamer/gst_cbs.h
+++ b/dlls/winegstreamer/gst_cbs.h
@@ -34,7 +34,6 @@ enum CB_TYPE {
     QUERY_FUNCTION,
     ACTIVATE_MODE,
     REQUEST_BUFFER_SRC,
-    EVENT_SRC,
     REMOVED_DECODED_PAD,
     QUERY_SINK,
     GSTDEMUX_MAX,
@@ -121,7 +120,6 @@ void existing_new_pad_wrapper(GstElement *bin, GstPad *pad, gpointer user) DECLS
 gboolean query_function_wrapper(GstPad *pad, GstObject *parent, GstQuery *query) DECLSPEC_HIDDEN;
 gboolean activate_mode_wrapper(GstPad *pad, GstObject *parent, GstPadMode mode, gboolean activate) DECLSPEC_HIDDEN;
 GstFlowReturn request_buffer_src_wrapper(GstPad *pad, GstObject *parent, guint64 ofs, guint len, GstBuffer **buf) DECLSPEC_HIDDEN;
-gboolean event_src_wrapper(GstPad *pad, GstObject *parent, GstEvent *event) DECLSPEC_HIDDEN;
 GstFlowReturn got_data_wrapper(GstPad *pad, GstObject *parent, GstBuffer *buf) DECLSPEC_HIDDEN;
 void removed_decoded_pad_wrapper(GstElement *bin, GstPad *pad, gpointer user) DECLSPEC_HIDDEN;
 void Gstreamer_transform_pad_added_wrapper(GstElement *filter, GstPad *pad, gpointer user) DECLSPEC_HIDDEN;
diff --git a/dlls/winegstreamer/gstdemux.c b/dlls/winegstreamer/gstdemux.c
index 3efec0f5295..b6c92e4807c 100644
--- a/dlls/winegstreamer/gstdemux.c
+++ b/dlls/winegstreamer/gstdemux.c
@@ -1518,7 +1518,7 @@ static HRESULT GST_Connect(struct parser *This, IPin *pConnectPin)
     gst_pad_set_getrange_function(This->my_src, request_buffer_src_wrapper);
     gst_pad_set_query_function(This->my_src, query_function_wrapper);
     gst_pad_set_activatemode_function(This->my_src, activate_mode_wrapper);
-    gst_pad_set_event_function(This->my_src, event_src_wrapper);
+    gst_pad_set_event_function(This->my_src, event_src);
     gst_pad_set_element_private (This->my_src, This);
 
     This->start = This->nextofs = This->nextpullofs = This->stop = 0;
@@ -2453,12 +2453,6 @@ void perform_cb_gstdemux(struct cb_data *cbdata)
                     data->ofs, data->len, data->buf);
             break;
         }
-    case EVENT_SRC:
-        {
-            struct event_src_data *data = &cbdata->u.event_src_data;
-            cbdata->u.event_src_data.ret = event_src(data->pad, data->parent, data->event);
-            break;
-        }
     case REMOVED_DECODED_PAD:
         {
             struct pad_removed_data *data = &cbdata->u.pad_removed_data;




More information about the wine-cvs mailing list