Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
2bf3bc3e
Commit
2bf3bc3e
authored
Sep 15, 2011
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
input/curl: add assertions on io_thread_inside()
parent
28143f86
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
curl_input_plugin.c
src/input/curl_input_plugin.c
+9
-0
No files found.
src/input/curl_input_plugin.c
View file @
2bf3bc3e
...
@@ -245,6 +245,8 @@ input_curl_fd_events(int fd, fd_set *rfds, fd_set *wfds, fd_set *efds)
...
@@ -245,6 +245,8 @@ input_curl_fd_events(int fd, fd_set *rfds, fd_set *wfds, fd_set *efds)
static
void
static
void
curl_update_fds
(
void
)
curl_update_fds
(
void
)
{
{
assert
(
io_thread_inside
());
fd_set
rfds
,
wfds
,
efds
;
fd_set
rfds
,
wfds
,
efds
;
FD_ZERO
(
&
rfds
);
FD_ZERO
(
&
rfds
);
...
@@ -305,6 +307,7 @@ curl_update_fds(void)
...
@@ -305,6 +307,7 @@ curl_update_fds(void)
static
gboolean
static
gboolean
input_curl_dirty_callback
(
G_GNUC_UNUSED
gpointer
data
)
input_curl_dirty_callback
(
G_GNUC_UNUSED
gpointer
data
)
{
{
assert
(
io_thread_inside
());
g_static_mutex_lock
(
&
curl
.
mutex
);
g_static_mutex_lock
(
&
curl
.
mutex
);
assert
(
curl
.
dirty_source_id
!=
0
||
curl
.
requests
==
NULL
);
assert
(
curl
.
dirty_source_id
!=
0
||
curl
.
requests
==
NULL
);
...
@@ -420,6 +423,7 @@ input_curl_easy_free_indirect(struct input_curl *c)
...
@@ -420,6 +423,7 @@ input_curl_easy_free_indirect(struct input_curl *c)
static
void
static
void
input_curl_abort_all_requests
(
GError
*
error
)
input_curl_abort_all_requests
(
GError
*
error
)
{
{
assert
(
io_thread_inside
());
assert
(
error
!=
NULL
);
assert
(
error
!=
NULL
);
while
(
curl
.
requests
!=
NULL
)
{
while
(
curl
.
requests
!=
NULL
)
{
...
@@ -443,6 +447,7 @@ input_curl_abort_all_requests(GError *error)
...
@@ -443,6 +447,7 @@ input_curl_abort_all_requests(GError *error)
static
void
static
void
input_curl_request_done
(
struct
input_curl
*
c
,
CURLcode
result
,
long
status
)
input_curl_request_done
(
struct
input_curl
*
c
,
CURLcode
result
,
long
status
)
{
{
assert
(
io_thread_inside
());
assert
(
c
!=
NULL
);
assert
(
c
!=
NULL
);
assert
(
c
->
easy
==
NULL
);
assert
(
c
->
easy
==
NULL
);
assert
(
c
->
base
.
ready
);
assert
(
c
->
base
.
ready
);
...
@@ -482,6 +487,8 @@ input_curl_handle_done(CURL *easy_handle, CURLcode result)
...
@@ -482,6 +487,8 @@ input_curl_handle_done(CURL *easy_handle, CURLcode result)
static
void
static
void
input_curl_info_read
(
void
)
input_curl_info_read
(
void
)
{
{
assert
(
io_thread_inside
());
CURLMsg
*
msg
;
CURLMsg
*
msg
;
int
msgs_in_queue
;
int
msgs_in_queue
;
...
@@ -500,6 +507,8 @@ input_curl_info_read(void)
...
@@ -500,6 +507,8 @@ input_curl_info_read(void)
static
bool
static
bool
input_curl_perform
(
void
)
input_curl_perform
(
void
)
{
{
assert
(
io_thread_inside
());
CURLMcode
mcode
;
CURLMcode
mcode
;
do
{
do
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment