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
4a75acb4
Commit
4a75acb4
authored
Aug 29, 2011
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
io_thread: add function io_thread_run()
parent
45336807
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
2 deletions
+16
-2
io_thread.c
src/io_thread.c
+8
-2
io_thread.h
src/io_thread.h
+8
-0
No files found.
src/io_thread.c
View file @
4a75acb4
...
...
@@ -31,13 +31,19 @@ static struct {
GThread
*
thread
;
}
io
;
static
gpointer
io_thread_
func
(
G_GNUC_UNUSED
gpointer
arg
)
void
io_thread_
run
(
void
)
{
assert
(
io
.
context
!=
NULL
);
assert
(
io
.
loop
!=
NULL
);
g_main_loop_run
(
io
.
loop
);
}
static
gpointer
io_thread_func
(
G_GNUC_UNUSED
gpointer
arg
)
{
io_thread_run
();
return
NULL
;
}
...
...
src/io_thread.h
View file @
4a75acb4
...
...
@@ -29,6 +29,14 @@ io_thread_init(void);
bool
io_thread_start
(
GError
**
error_r
);
/**
* Run the I/O event loop synchronously in the current thread. This
* can be called instead of io_thread_start(). For testing purposes
* only.
*/
void
io_thread_run
(
void
);
void
io_thread_deinit
(
void
);
...
...
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