mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-31 22:25:33 -04:00
add validity check for the "server" parameter of pa_context_connect()
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@536 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
0858ef9bed
commit
2bdc07e2ea
1 changed files with 1 additions and 0 deletions
|
|
@ -624,6 +624,7 @@ int pa_context_connect(
|
|||
|
||||
PA_CHECK_VALIDITY(c, c->state == PA_CONTEXT_UNCONNECTED, PA_ERR_BADSTATE);
|
||||
PA_CHECK_VALIDITY(c, !(flags & ~PA_CONTEXT_NOAUTOSPAWN), PA_ERR_INVALID);
|
||||
PA_CHECK_VALIDITY(c, !server || *server, PA_ERR_INVALID);
|
||||
|
||||
if (!server)
|
||||
server = c->conf->default_server;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue