mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-16 08:56:45 -05:00
treewide: replace strcmp() == 0 with spa_streq()
This change is only done in source files for now, header files will be done separately.
This commit is contained in:
parent
d8a9534a9a
commit
7697ed0757
130 changed files with 817 additions and 675 deletions
|
|
@ -39,6 +39,7 @@
|
|||
#include <spa/utils/result.h>
|
||||
#include <spa/utils/type.h>
|
||||
#include <spa/utils/ringbuffer.h>
|
||||
#include <spa/utils/string.h>
|
||||
|
||||
#define NAME "loop"
|
||||
|
||||
|
|
@ -706,11 +707,11 @@ static int impl_get_interface(struct spa_handle *handle, const char *type, void
|
|||
|
||||
impl = (struct impl *) handle;
|
||||
|
||||
if (strcmp(type, SPA_TYPE_INTERFACE_Loop) == 0)
|
||||
if (spa_streq(type, SPA_TYPE_INTERFACE_Loop))
|
||||
*interface = &impl->loop;
|
||||
else if (strcmp(type, SPA_TYPE_INTERFACE_LoopControl) == 0)
|
||||
else if (spa_streq(type, SPA_TYPE_INTERFACE_LoopControl))
|
||||
*interface = &impl->control;
|
||||
else if (strcmp(type, SPA_TYPE_INTERFACE_LoopUtils) == 0)
|
||||
else if (spa_streq(type, SPA_TYPE_INTERFACE_LoopUtils))
|
||||
*interface = &impl->utils;
|
||||
else
|
||||
return -ENOENT;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue