mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
treewide: mark things static and const
Mark some structures, arrays static/const at various places. In some cases this prevents unnecessary initialization when a function is entered. All in all, the text segments across all shared libraries are reduced by about 2 KiB. However, the total size increases by about 2 KiB as well.
This commit is contained in:
parent
48dbb4da3c
commit
f5d51162c4
54 changed files with 303 additions and 241 deletions
|
|
@ -2015,7 +2015,7 @@ pw_protocol_native_registry_event_demarshal[PW_REGISTRY_EVENT_NUM] =
|
|||
[PW_REGISTRY_EVENT_GLOBAL_REMOVE] = { ®istry_demarshal_global_remove, 0, }
|
||||
};
|
||||
|
||||
const struct pw_protocol_marshal pw_protocol_native_registry_marshal = {
|
||||
static const struct pw_protocol_marshal pw_protocol_native_registry_marshal = {
|
||||
PW_TYPE_INTERFACE_Registry,
|
||||
PW_VERSION_REGISTRY,
|
||||
0,
|
||||
|
|
@ -2050,7 +2050,7 @@ pw_protocol_native_module_method_demarshal[PW_MODULE_METHOD_NUM] =
|
|||
[PW_MODULE_METHOD_ADD_LISTENER] = { NULL, 0, },
|
||||
};
|
||||
|
||||
const struct pw_protocol_marshal pw_protocol_native_module_marshal = {
|
||||
static const struct pw_protocol_marshal pw_protocol_native_module_marshal = {
|
||||
PW_TYPE_INTERFACE_Module,
|
||||
PW_VERSION_MODULE,
|
||||
0,
|
||||
|
|
@ -2084,7 +2084,7 @@ pw_protocol_native_factory_method_demarshal[PW_FACTORY_METHOD_NUM] =
|
|||
[PW_FACTORY_METHOD_ADD_LISTENER] = { NULL, 0, },
|
||||
};
|
||||
|
||||
const struct pw_protocol_marshal pw_protocol_native_factory_marshal = {
|
||||
static const struct pw_protocol_marshal pw_protocol_native_factory_marshal = {
|
||||
PW_TYPE_INTERFACE_Factory,
|
||||
PW_VERSION_FACTORY,
|
||||
0,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
|
||||
const struct type_info {
|
||||
static const struct type_info {
|
||||
const char *type;
|
||||
const char *name;
|
||||
uint32_t id;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue