mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-05-16 21:37:49 -04:00
pipewire: remove cleanup.h
Since `spa/utils/cleanup.h` is not a private header anymore, there is no need for a separate `pipewire/cleanup.h` since the definitions of the cleanup routines can now be moved into the respective headers.
This commit is contained in:
parent
80df1957bf
commit
b3bd026699
25 changed files with 23 additions and 43 deletions
|
|
@ -1,21 +0,0 @@
|
|||
/* PipeWire */
|
||||
/* SPDX-FileCopyrightText: Copyright © 2023 PipeWire authors */
|
||||
/* SPDX-License-Identifier: MIT */
|
||||
|
||||
#ifndef PIPEWIRE_CLEANUP_H
|
||||
#define PIPEWIRE_CLEANUP_H
|
||||
|
||||
#include <spa/utils/cleanup.h>
|
||||
|
||||
#include <pipewire/properties.h>
|
||||
#include <pipewire/utils.h>
|
||||
|
||||
SPA_DEFINE_AUTOPTR_CLEANUP(pw_properties, struct pw_properties, {
|
||||
spa_clear_ptr(*thing, pw_properties_free);
|
||||
})
|
||||
|
||||
SPA_DEFINE_AUTO_CLEANUP(pw_strv, char **, {
|
||||
spa_clear_ptr(*thing, pw_free_strv);
|
||||
})
|
||||
|
||||
#endif /* PIPEWIRE_CLEANUP_H */
|
||||
|
|
@ -24,12 +24,12 @@
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/result.h>
|
||||
#include <spa/utils/string.h>
|
||||
#include <spa/utils/json.h>
|
||||
#include <spa/debug/log.h>
|
||||
|
||||
#include <pipewire/cleanup.h>
|
||||
#include <pipewire/impl.h>
|
||||
#include <pipewire/private.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -12,13 +12,13 @@
|
|||
#include <spa/param/props.h>
|
||||
#include <spa/node/io.h>
|
||||
#include <spa/node/utils.h>
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/ringbuffer.h>
|
||||
#include <spa/utils/string.h>
|
||||
#include <spa/pod/filter.h>
|
||||
#include <spa/pod/dynamic.h>
|
||||
#include <spa/debug/types.h>
|
||||
|
||||
#include <pipewire/cleanup.h>
|
||||
#include "pipewire/pipewire.h"
|
||||
#include "pipewire/filter.h"
|
||||
#include "pipewire/private.h"
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
#include <spa/utils/json-pod.h>
|
||||
|
||||
#include "pipewire/impl.h"
|
||||
#include "pipewire/cleanup.h"
|
||||
#include "pipewire/private.h"
|
||||
|
||||
PW_LOG_TOPIC_EXTERN(log_device);
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@
|
|||
#include <errno.h>
|
||||
|
||||
#include <spa/debug/types.h>
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/string.h>
|
||||
|
||||
#include <pipewire/cleanup.h>
|
||||
#include "pipewire/impl.h"
|
||||
#include "pipewire/private.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -13,9 +13,9 @@
|
|||
#include <sys/stat.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/string.h>
|
||||
|
||||
#include <pipewire/cleanup.h>
|
||||
#include "pipewire/impl.h"
|
||||
#include "pipewire/private.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
#include <pipewire/log.h>
|
||||
#include <pipewire/private.h>
|
||||
#include <pipewire/cleanup.h>
|
||||
|
||||
SPA_LOG_IMPL(default_log);
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
#include <spa/support/cpu.h>
|
||||
#include <spa/support/i18n.h>
|
||||
|
||||
#include <pipewire/cleanup.h>
|
||||
#include "pipewire.h"
|
||||
#include "private.h"
|
||||
#include "i18n.h"
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ extern "C" {
|
|||
|
||||
#include <stdarg.h>
|
||||
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/dict.h>
|
||||
#include <spa/utils/string.h>
|
||||
|
||||
|
|
@ -184,6 +185,10 @@ static inline double pw_properties_parse_double(const char *value) {
|
|||
* \}
|
||||
*/
|
||||
|
||||
SPA_DEFINE_AUTOPTR_CLEANUP(pw_properties, struct pw_properties, {
|
||||
spa_clear_ptr(*thing, pw_properties_free);
|
||||
})
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@
|
|||
#include <spa/param/format-utils.h>
|
||||
#include <spa/node/io.h>
|
||||
#include <spa/node/utils.h>
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/ringbuffer.h>
|
||||
#include <spa/pod/filter.h>
|
||||
#include <spa/pod/dynamic.h>
|
||||
|
|
@ -20,7 +21,6 @@
|
|||
|
||||
#define PW_ENABLE_DEPRECATED
|
||||
|
||||
#include <pipewire/cleanup.h>
|
||||
#include "pipewire/pipewire.h"
|
||||
#include "pipewire/stream.h"
|
||||
#include "pipewire/private.h"
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@ extern "C" {
|
|||
#define ENODATA 9919
|
||||
#endif
|
||||
|
||||
#include <spa/utils/cleanup.h>
|
||||
#include <spa/utils/defs.h>
|
||||
#include <spa/pod/pod.h>
|
||||
|
||||
|
|
@ -99,6 +100,10 @@ void* pw_reallocarray(void *ptr, size_t nmemb, size_t size);
|
|||
* \}
|
||||
*/
|
||||
|
||||
SPA_DEFINE_AUTO_CLEANUP(pw_strv, char **, {
|
||||
spa_clear_ptr(*thing, pw_free_strv);
|
||||
})
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* extern "C" */
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue