mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-12-18 08:56:40 -05:00
add support for automatic termination of the daemon after the last client quit
remove all gcc warnings add boolean types for tagstruct and modargs git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@178 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
fb962b67db
commit
57e473b61c
23 changed files with 155 additions and 37 deletions
|
|
@ -51,6 +51,8 @@ struct pa_client *pa_client_new(struct pa_core *core, const char *protocol_name,
|
|||
|
||||
fprintf(stderr, "client: created %u \"%s\"\n", c->index, c->name);
|
||||
pa_subscription_post(core, PA_SUBSCRIPTION_EVENT_CLIENT|PA_SUBSCRIPTION_EVENT_NEW, c->index);
|
||||
|
||||
pa_core_check_quit(core);
|
||||
|
||||
return c;
|
||||
}
|
||||
|
|
@ -59,10 +61,14 @@ void pa_client_free(struct pa_client *c) {
|
|||
assert(c && c->core);
|
||||
|
||||
pa_idxset_remove_by_data(c->core->clients, c, NULL);
|
||||
|
||||
pa_core_check_quit(c->core);
|
||||
|
||||
fprintf(stderr, "client: freed %u \"%s\"\n", c->index, c->name);
|
||||
pa_subscription_post(c->core, PA_SUBSCRIPTION_EVENT_CLIENT|PA_SUBSCRIPTION_EVENT_REMOVE, c->index);
|
||||
pa_xfree(c->name);
|
||||
pa_xfree(c);
|
||||
|
||||
}
|
||||
|
||||
void pa_client_kill(struct pa_client *c) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue