mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-05 15:08:48 +00:00
adaptivedemux2/downloadhelper: Remove return val for download_request_add_buffer()
The function can't actually fail, and the only caller was ignoring the result anyway, so remove the return value. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3314>
This commit is contained in:
parent
0f8c38c190
commit
bfeb3c5625
2 changed files with 5 additions and 7 deletions
|
@ -367,18 +367,18 @@ download_request_get_caps (DownloadRequest * request)
|
||||||
return caps;
|
return caps;
|
||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
void
|
||||||
download_request_add_buffer (DownloadRequest * request, GstBuffer * buffer)
|
download_request_add_buffer (DownloadRequest * request, GstBuffer * buffer)
|
||||||
{
|
{
|
||||||
DownloadRequestPrivate *priv = DOWNLOAD_REQUEST_PRIVATE (request);
|
DownloadRequestPrivate *priv = DOWNLOAD_REQUEST_PRIVATE (request);
|
||||||
|
|
||||||
g_return_val_if_fail (request != NULL, FALSE);
|
g_return_if_fail (request != NULL);
|
||||||
g_return_val_if_fail (buffer != NULL, FALSE);
|
g_return_if_fail (buffer != NULL);
|
||||||
|
|
||||||
if (request->state == DOWNLOAD_REQUEST_STATE_COMPLETE) {
|
if (request->state == DOWNLOAD_REQUEST_STATE_COMPLETE) {
|
||||||
GST_WARNING ("Download request is completed, could not add more buffers");
|
GST_WARNING ("Download request is completed, could not add more buffers");
|
||||||
gst_buffer_unref (buffer);
|
gst_buffer_unref (buffer);
|
||||||
return FALSE;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
GST_DEBUG ("Adding new buffer %" GST_PTR_FORMAT " to the request data",
|
GST_DEBUG ("Adding new buffer %" GST_PTR_FORMAT " to the request data",
|
||||||
|
@ -391,6 +391,4 @@ download_request_add_buffer (DownloadRequest * request, GstBuffer * buffer)
|
||||||
priv->buffer = buffer;
|
priv->buffer = buffer;
|
||||||
else
|
else
|
||||||
priv->buffer = gst_buffer_append (priv->buffer, buffer);
|
priv->buffer = gst_buffer_append (priv->buffer, buffer);
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -83,7 +83,7 @@ void download_request_set_caps (DownloadRequest * request, GstCaps * caps);
|
||||||
|
|
||||||
GstCaps * download_request_get_caps (DownloadRequest * request);
|
GstCaps * download_request_get_caps (DownloadRequest * request);
|
||||||
|
|
||||||
gboolean download_request_add_buffer (DownloadRequest *request, GstBuffer *buffer);
|
void download_request_add_buffer (DownloadRequest *request, GstBuffer *buffer);
|
||||||
GstBuffer * download_request_take_buffer (DownloadRequest *request);
|
GstBuffer * download_request_take_buffer (DownloadRequest *request);
|
||||||
|
|
||||||
DownloadRequest * download_request_new (void);
|
DownloadRequest * download_request_new (void);
|
||||||
|
|
Loading…
Reference in a new issue