mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-10-02 16:52:42 +00:00
rtsp-server: Fix compilation and compiler warnings
This commit is contained in:
parent
7df1696713
commit
e2f10f5ba5
3 changed files with 9 additions and 11 deletions
|
@ -189,7 +189,7 @@ default_check_method (GstRTSPAuth * auth, GstRTSPClient * client,
|
||||||
gboolean result = TRUE;
|
gboolean result = TRUE;
|
||||||
GstRTSPResult res;
|
GstRTSPResult res;
|
||||||
|
|
||||||
if (state->method & auth->methods != 0) {
|
if ((state->method & auth->methods) != 0) {
|
||||||
gchar *authorization;
|
gchar *authorization;
|
||||||
|
|
||||||
result = FALSE;
|
result = FALSE;
|
||||||
|
@ -221,7 +221,7 @@ no_auth:
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* gst_rtsp_auth_check_method:
|
* gst_rtsp_auth_check:
|
||||||
* @auth: a #GstRTSPAuth
|
* @auth: a #GstRTSPAuth
|
||||||
* @client: the client
|
* @client: the client
|
||||||
* @hint: a hint
|
* @hint: a hint
|
||||||
|
|
|
@ -70,7 +70,7 @@ void gst_rtsp_auth_set_basic (GstRTSPAuth *auth, const gc
|
||||||
|
|
||||||
gboolean gst_rtsp_auth_setup_auth (GstRTSPAuth *auth, GstRTSPClient * client,
|
gboolean gst_rtsp_auth_setup_auth (GstRTSPAuth *auth, GstRTSPClient * client,
|
||||||
GQuark hint, GstRTSPClientState *state);
|
GQuark hint, GstRTSPClientState *state);
|
||||||
gboolean gst_rtsp_auth_check_method (GstRTSPAuth *auth, GstRTSPClient * client,
|
gboolean gst_rtsp_auth_check (GstRTSPAuth *auth, GstRTSPClient * client,
|
||||||
GQuark hint, GstRTSPClientState *state);
|
GQuark hint, GstRTSPClientState *state);
|
||||||
/* helpers */
|
/* helpers */
|
||||||
gchar * gst_rtsp_auth_make_basic (const gchar * user, const gchar * pass);
|
gchar * gst_rtsp_auth_make_basic (const gchar * user, const gchar * pass);
|
||||||
|
|
|
@ -429,7 +429,7 @@ do_send_data_list (GstBufferList * blist, guint8 channel,
|
||||||
{
|
{
|
||||||
guint len, i;
|
guint len, i;
|
||||||
|
|
||||||
len = gst_buffer_list_len (blist);
|
len = gst_buffer_list_length (blist);
|
||||||
|
|
||||||
for (i = 0; i < len; i++) {
|
for (i = 0; i < len; i++) {
|
||||||
GstBuffer *group = gst_buffer_list_get (blist, i);
|
GstBuffer *group = gst_buffer_list_get (blist, i);
|
||||||
|
@ -1351,7 +1351,7 @@ handle_request (GstRTSPClient * client, GstRTSPMessage * request)
|
||||||
state.session = session;
|
state.session = session;
|
||||||
|
|
||||||
if (client->auth) {
|
if (client->auth) {
|
||||||
if (!gst_rtsp_auth_check (client->auth, client, &state))
|
if (!gst_rtsp_auth_check (client->auth, client, 0, &state))
|
||||||
goto not_authorized;
|
goto not_authorized;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1433,9 +1433,7 @@ handle_data (GstRTSPClient * client, GstRTSPMessage * message)
|
||||||
|
|
||||||
gst_rtsp_message_steal_body (message, &data, &size);
|
gst_rtsp_message_steal_body (message, &data, &size);
|
||||||
|
|
||||||
buffer = gst_buffer_new ();
|
buffer = gst_buffer_new_wrapped (data, size);
|
||||||
gst_buffer_take_memory (buffer, -1,
|
|
||||||
gst_memory_new_wrapped (0, data, size, 0, size, data, g_free));
|
|
||||||
|
|
||||||
handled = FALSE;
|
handled = FALSE;
|
||||||
for (walk = client->streams; walk; walk = g_list_next (walk)) {
|
for (walk = client->streams; walk; walk = g_list_next (walk)) {
|
||||||
|
@ -1849,20 +1847,20 @@ tunnel_complete (GstRTSPWatch * watch, gpointer user_data)
|
||||||
no_tunnelid:
|
no_tunnelid:
|
||||||
{
|
{
|
||||||
GST_INFO ("client %p: no tunnelid provided", client);
|
GST_INFO ("client %p: no tunnelid provided", client);
|
||||||
return GST_RTSP_STS_SERVICE_UNAVAILABLE;
|
return GST_RTSP_ERROR;
|
||||||
}
|
}
|
||||||
no_tunnel:
|
no_tunnel:
|
||||||
{
|
{
|
||||||
g_mutex_unlock (tunnels_lock);
|
g_mutex_unlock (tunnels_lock);
|
||||||
GST_INFO ("client %p: tunnel session %s not found", client, tunnelid);
|
GST_INFO ("client %p: tunnel session %s not found", client, tunnelid);
|
||||||
return GST_RTSP_STS_SERVICE_UNAVAILABLE;
|
return GST_RTSP_ERROR;
|
||||||
}
|
}
|
||||||
tunnel_closed:
|
tunnel_closed:
|
||||||
{
|
{
|
||||||
g_mutex_unlock (tunnels_lock);
|
g_mutex_unlock (tunnels_lock);
|
||||||
GST_INFO ("client %p: tunnel session %s was closed", client, tunnelid);
|
GST_INFO ("client %p: tunnel session %s was closed", client, tunnelid);
|
||||||
g_object_unref (oclient);
|
g_object_unref (oclient);
|
||||||
return GST_RTSP_STS_SERVICE_UNAVAILABLE;
|
return GST_RTSP_ERROR;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue