mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
spa: libcamera: don't calculate id twice
This commit is contained in:
parent
bb1c2c3272
commit
9eab76d862
1 changed files with 2 additions and 2 deletions
|
|
@ -112,9 +112,9 @@ static struct device *add_device(struct impl *impl, std::shared_ptr<Camera> came
|
|||
|
||||
if (impl->n_devices >= MAX_DEVICES)
|
||||
return NULL;
|
||||
id = get_free_id(impl);;
|
||||
id = get_free_id(impl);
|
||||
device = &impl->devices[id];
|
||||
device->id = get_free_id(impl);;
|
||||
device->id = id;
|
||||
device->camera = std::move(camera);
|
||||
impl->n_devices++;
|
||||
return device;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue