input/curl: pass input_curl to fill_buffer()
Remove a cast.
This commit is contained in:
parent
635f7026b0
commit
f8f3bc89e7
@ -319,9 +319,8 @@ input_curl_select(struct input_curl *c, GError **error_r)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
fill_buffer(struct input_stream *is, GError **error_r)
|
fill_buffer(struct input_curl *c, GError **error_r)
|
||||||
{
|
{
|
||||||
struct input_curl *c = (struct input_curl *)is;
|
|
||||||
CURLMcode mcode = CURLM_CALL_MULTI_PERFORM;
|
CURLMcode mcode = CURLM_CALL_MULTI_PERFORM;
|
||||||
|
|
||||||
while (!c->eof && g_queue_is_empty(c->buffers)) {
|
while (!c->eof && g_queue_is_empty(c->buffers)) {
|
||||||
@ -343,7 +342,7 @@ fill_buffer(struct input_stream *is, GError **error_r)
|
|||||||
"curl_multi_perform() failed: %s",
|
"curl_multi_perform() failed: %s",
|
||||||
curl_multi_strerror(mcode));
|
curl_multi_strerror(mcode));
|
||||||
c->eof = true;
|
c->eof = true;
|
||||||
is->ready = true;
|
c->base.ready = true;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -457,7 +456,7 @@ input_curl_read(struct input_stream *is, void *ptr, size_t size,
|
|||||||
do {
|
do {
|
||||||
/* fill the buffer */
|
/* fill the buffer */
|
||||||
|
|
||||||
success = fill_buffer(is, error_r);
|
success = fill_buffer(c, error_r);
|
||||||
if (!success)
|
if (!success)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user