Revert "WIP revert soup"

This reverts commit fdac3a7a23.

Was not supposed to be pushed but a local workaround for
https://bugzilla.gnome.org/show_bug.cgi?id=693911#c13
This commit is contained in:
Sebastian Dröge 2016-06-06 10:47:52 +03:00
parent 389e0abeb0
commit 4a2455b744
4 changed files with 317 additions and 497 deletions

View file

@ -4,8 +4,8 @@ libgstsouphttpsrc_la_SOURCES = gstsouphttpsrc.c gstsouphttpclientsink.c gstsoupu
libgstsouphttpsrc_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) \ libgstsouphttpsrc_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) \
$(GST_CFLAGS) $(SOUP_CFLAGS) \ $(GST_CFLAGS) $(SOUP_CFLAGS) \
-DSOUP_VERSION_MIN_REQUIRED=SOUP_VERSION_2_26 \ -DSOUP_VERSION_MIN_REQUIRED=SOUP_VERSION_2_48 \
-DSOUP_VERSION_MAX_ALLOWED=SOUP_DEPRECATED_IN_2_26 -DSOUP_VERSION_MAX_ALLOWED=SOUP_DEPRECATED_IN_2_48
libgstsouphttpsrc_la_LIBADD = $(GST_PLUGINS_BASE_LIBS) -lgsttag-@GST_API_VERSION@ $(GST_BASE_LIBS) $(SOUP_LIBS) libgstsouphttpsrc_la_LIBADD = $(GST_PLUGINS_BASE_LIBS) -lgsttag-@GST_API_VERSION@ $(GST_BASE_LIBS) $(SOUP_LIBS)
libgstsouphttpsrc_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) libgstsouphttpsrc_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
libgstsouphttpsrc_la_LIBTOOLFLAGS = $(GST_PLUGIN_LIBTOOLFLAGS) libgstsouphttpsrc_la_LIBTOOLFLAGS = $(GST_PLUGIN_LIBTOOLFLAGS)

View file

@ -264,8 +264,10 @@ gst_soup_http_client_sink_reset (GstSoupHttpClientSink * souphttpsink)
g_list_free_full (souphttpsink->streamheader_buffers, g_list_free_full (souphttpsink->streamheader_buffers,
(GDestroyNotify) gst_buffer_unref); (GDestroyNotify) gst_buffer_unref);
souphttpsink->streamheader_buffers = NULL;
g_list_free_full (souphttpsink->sent_buffers, g_list_free_full (souphttpsink->sent_buffers,
(GDestroyNotify) gst_buffer_unref); (GDestroyNotify) gst_buffer_unref);
souphttpsink->sent_buffers = NULL;
} }
static gboolean static gboolean

File diff suppressed because it is too large Load diff

View file

@ -59,16 +59,9 @@ struct _GstSoupHTTPSrc {
gchar *proxy_id; /* Authentication user id for proxy URI. */ gchar *proxy_id; /* Authentication user id for proxy URI. */
gchar *proxy_pw; /* Authentication user password for proxy URI. */ gchar *proxy_pw; /* Authentication user password for proxy URI. */
gchar **cookies; /* HTTP request cookies. */ gchar **cookies; /* HTTP request cookies. */
GMainContext *context; /* I/O context. */
GMainLoop *loop; /* Event loop. */
SoupSession *session; /* Async context. */ SoupSession *session; /* Async context. */
GstSoupHTTPSrcSessionIOStatus session_io_status;
/* Async I/O status. */
SoupMessage *msg; /* Request message. */ SoupMessage *msg; /* Request message. */
GstFlowReturn ret; /* Return code from callback. */ GstFlowReturn ret; /* Return code from callback. */
GstBuffer **outbuf; /* Return buffer allocated by callback. */
gboolean interrupted; /* Signal unlock(). */
gboolean retry; /* Should attempt to reconnect. */
gint retry_count; /* Number of retries since we received data */ gint retry_count; /* Number of retries since we received data */
gint max_retries; /* Maximum number of retries */ gint max_retries; /* Maximum number of retries */
gchar *method; /* HTTP method */ gchar *method; /* HTTP method */
@ -94,6 +87,13 @@ struct _GstSoupHTTPSrc {
GTlsDatabase *tls_database; GTlsDatabase *tls_database;
GTlsInteraction *tls_interaction; GTlsInteraction *tls_interaction;
GCancellable *cancellable;
GInputStream *input_stream;
gboolean has_pollable_interface;
gboolean have_data;
GMainContext *poll_context;
GSource *poll_source;
/* Shoutcast/icecast metadata extraction handling. */ /* Shoutcast/icecast metadata extraction handling. */
gboolean iradio_mode; gboolean iradio_mode;
GstCaps *src_caps; GstCaps *src_caps;
@ -110,7 +110,7 @@ struct _GstSoupHTTPSrc {
guint timeout; guint timeout;
GMutex mutex; GMutex mutex;
GCond request_finished_cond; GCond have_headers_cond;
GstEvent *http_headers_event; GstEvent *http_headers_event;
}; };