mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-03 09:01:50 -05:00
core: Ignore pa_shared_remove() return value
document behaviour of pa_shared_remove() in case name does not exist Coverity ID: #1380672 thanks to Georg Chini for suggesting to swap patch title and commit message Signed-off-by: Peter Meerwald-Stadler <pmeerw@pmeerw.net>
This commit is contained in:
parent
976f7e9a61
commit
eab0b9d83b
2 changed files with 4 additions and 2 deletions
|
|
@ -111,6 +111,6 @@ int pa_shared_replace(pa_core *c, const char *name, void *data) {
|
|||
pa_assert(c);
|
||||
pa_assert(name);
|
||||
|
||||
pa_shared_remove(c, name);
|
||||
(void) pa_shared_remove(c, name);
|
||||
return pa_shared_set(c, name, data);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,7 +44,9 @@ int pa_shared_set(pa_core *c, const char *name, void *data);
|
|||
/* Remove the specified shared property. Return non-zero on failure */
|
||||
int pa_shared_remove(pa_core *c, const char *name);
|
||||
|
||||
/* A combination of pa_shared_remove() and pa_shared_set() */
|
||||
/* A combination of pa_shared_remove() and pa_shared_set(); this function
|
||||
* first tries to remove the property by this name and then sets the
|
||||
* property. Return non-zero on failure. */
|
||||
int pa_shared_replace(pa_core *c, const char *name, void *data);
|
||||
|
||||
/* Dump the current set of shared properties */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue