mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-08 13:29:59 -05:00
fix a typo and some minor optimizations
git-svn-id: file:///home/lennart/svn/public/pulseaudio/branches/lennart@1487 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
1c9bd201ec
commit
fff9081c4b
1 changed files with 7 additions and 8 deletions
|
|
@ -99,8 +99,6 @@ static void thread_func(void *userdata) {
|
|||
|
||||
pa_log_debug("Thread starting up");
|
||||
|
||||
pa_memchunk_reset(&u->memchunk);
|
||||
|
||||
memset(&pollfd, 0, sizeof(pollfd));
|
||||
|
||||
pollfd[POLLFD_ASYNCQ].fd = pa_asyncmsgq_get_fd(u->asyncmsgq);
|
||||
|
|
@ -128,7 +126,7 @@ static void thread_func(void *userdata) {
|
|||
continue;
|
||||
}
|
||||
|
||||
/* Render some data and write it to the fifo */
|
||||
/* Try to read some data and pass it on to the source driver */
|
||||
|
||||
if (u->source->thread_info.state == PA_SOURCE_RUNNING && pollfd[POLLFD_FIFO].revents) {
|
||||
void *p;
|
||||
|
|
@ -172,7 +170,7 @@ static void thread_func(void *userdata) {
|
|||
}
|
||||
}
|
||||
|
||||
pollfd[POLLFD_FIFO].events = u->source->thread_info.state == PA_SINK_RUNNING ? POLLIN : 0;
|
||||
pollfd[POLLFD_FIFO].events = u->source->thread_info.state == PA_SOURCE_RUNNING ? POLLIN : 0;
|
||||
|
||||
/* Hmm, nothing to do. Let's sleep */
|
||||
|
||||
|
|
@ -237,6 +235,7 @@ int pa__init(pa_core *c, pa_module*m) {
|
|||
u->core = c;
|
||||
u->module = m;
|
||||
m->userdata = u;
|
||||
pa_memchunk_reset(&u->memchunk);
|
||||
|
||||
pa_assert_se(u->asyncmsgq = pa_asyncmsgq_new(0));
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue