mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-02 09:01:50 -05:00
plugin: increment version and avoid inspecting old versions
There are incompatible version 0 plugins around (the compat ones) that crash spa-inspect. Increment the version number to avoid this.
This commit is contained in:
parent
2c76ec5193
commit
539be881ba
2 changed files with 7 additions and 1 deletions
|
|
@ -99,7 +99,7 @@ static inline void *spa_support_find(const struct spa_support *support,
|
|||
|
||||
struct spa_handle_factory {
|
||||
/** The version of this structure */
|
||||
#define SPA_VERSION_HANDLE_FACTORY 0
|
||||
#define SPA_VERSION_HANDLE_FACTORY 1
|
||||
uint32_t version;
|
||||
/**
|
||||
* The name of the factory contains a logical name that describes
|
||||
|
|
|
|||
|
|
@ -203,7 +203,13 @@ static void inspect_factory(struct data *data, const struct spa_handle_factory *
|
|||
const struct spa_interface_info *info;
|
||||
uint32_t index;
|
||||
|
||||
printf("factory version:\t\t%d\n", factory->version);
|
||||
printf("factory name:\t\t'%s'\n", factory->name);
|
||||
if (factory->version < SPA_VERSION_HANDLE_FACTORY) {
|
||||
printf("\tno further info for version < %d\n", SPA_VERSION_HANDLE_FACTORY);
|
||||
return;
|
||||
}
|
||||
|
||||
printf("factory info:\n");
|
||||
if (factory->info)
|
||||
spa_debug_dict(2, factory->info);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue