pipewire/pipewire-jack/src
Nedko Arnaudov 6544996a33 pipewire-jack: emit foreign port registration callbacks on jack_activate
The jack_activate loop was only queuing NOTIFY_TYPE_PORTREGISTRATION
for the activating client's own ports. Ports belonging to other clients
— including all WirePlumber-managed ports and MIDI ports — were silently
skipped due to the o->port.port->client != c condition.

This caused two observable bugs for clients using libjackserver (e.g.
jackdbus):
- JackPortRegistrationCallback was not fired for any pre-existing
  foreign ports at activate time, leaving the patchbay empty unless
  the session manager happened to start after the client.
- JACK MIDI ports were never announced via callback, even though they
  are correctly returned by jack_get_ports().

The graph_order_callback fallback (used by jackdbus for initial port
enumeration) is also ineffective here because pipewire-jack only fires
it on connection events, not on activate.

Fix by iterating all non-removed foreign ports in the object list and
queuing registration callbacks for those whose node is active, matching
the semantics already implemented in node_info() for ports of nodes
that transition to running state after activate.

The change is libjackserver.so only. libjack.so behaviour is left
unmodifed, as carla is showing ports of each client twice.
2026-03-13 09:21:20 +01:00
..
control.c jack: make jackctl_server_close() succeed (still dummy) 2024-08-29 14:22:58 +02:00
dummy.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
export.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
meson.build pipewire-jack: emit foreign port registration callbacks on jack_activate 2026-03-13 09:21:20 +01:00
metadata.c Jack: Added missing lock to jack API call 2024-02-08 10:20:12 +01:00
net.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
pipewire-jack-extensions.h jack: Add UMP to MIDI conversions 2024-07-29 18:15:58 +02:00
pipewire-jack.c pipewire-jack: emit foreign port registration callbacks on jack_activate 2026-03-13 09:21:20 +01:00
pw-jack.in pipewire-jack: Disable LD_LIBRARY_PATH when libjack is in libdir 2023-09-15 08:49:36 +00:00
ringbuffer.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
statistics.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
uuid.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00