Commit Graph

67 Commits

Author SHA1 Message Date
Nedko Arnaudov 1b66932459 ladishd: properly detect connect failures
This fixes a bug when port is appearing, connect attempt is made,
connect fails because port has just disappeared, port reappears then
but new connect attempt was not made. Happens quite easily with
wineasio apps that "probe" (nuendo2 for example).
2010-11-01 21:28:28 +02:00
Nedko Arnaudov 698bf81a3b daemon: better handling for non-direct childs. Fixes #62
If the first JACK client that appears has pid different from the one
of the child process, send SIGUSR1 on L1 save to this first
grandchild.

This changeset fixes the "run L1 app in terminal" issue and the
similar issue with dash (the default shell on Debian and Ubuntu, that
for simple commandlines does fork() and exec() instead of just exec(),
like bash does. This changeset also fixes the situation with complex
commandlines that result in only one JACK client.

The complex commandlines that result in multiple processes creating
JACK clients are handled by sending the SIGUSR1 to the first process
that creates JACK client. In future this could be improved by sending
SIGUSR1 to all of them but it is probably better to avoid such
situations by creating one app per JACK-creating process.
2010-10-24 03:03:25 +03:00
Nedko Arnaudov 1ee3607bd8 Merge branch 'confd' 2010-09-28 00:21:13 +03:00
Nedko Arnaudov 905ccfbb10 ladishd: remove unused function parameter 2010-09-22 00:29:39 +03:00
Nedko Arnaudov ef3a3891db move catdup to common/ 2010-09-19 17:15:11 +03:00
Nedko Arnaudov e06f5b73dd daemon: save connections of stopped apps. #100 2010-08-30 04:14:25 +03:00
Nedko Arnaudov ac1de1cc6a daemon: handle rename of apps that have non-unique names 2010-08-30 00:40:17 +03:00
Nedko Arnaudov 76a8b6161b daemon: handle apps with same name in different vgraphs 2010-08-30 00:05:57 +03:00
Nedko Arnaudov 399aaeaaf1 daemon: Fix for #97
Try to supply alternative fake strings if mapping fails
2010-07-23 03:59:12 +03:00
Nedko Arnaudov 229c4f2c0d daemon: more fixes for #94
* properly handle removal of apps with portless JACK clients
 * properly handle removal of a2j
2010-05-29 23:13:30 +03:00
Nedko Arnaudov 892c22d7ea Properly handle stop of apps with jack clients without ports. Fix for #94 2010-05-29 15:36:53 +03:00
Nedko Arnaudov 46bcf78914 daemon: fix removing of apps without jack client
see previous commit as well
2010-05-26 00:53:36 +03:00
Nedko Arnaudov 45fc0336c2 daemon: Properly handle apps without JACK clients
Fixes #94
2010-05-26 00:34:20 +03:00
Nedko Arnaudov 8925772da6 daemon: ladish_studio_get_jack_graph()
For use instead of ladish_studio_get_virtualizer()
because the later will return NULL when JACK server is stopped
2010-05-16 11:17:09 +03:00
Nedko Arnaudov 18ba50dafb daemon: on app stop, wait its client to disappear 2010-05-13 03:18:23 +03:00
Nedko Arnaudov 76aba4487b daemon: Interlink clients when loading studio from disk 2010-05-13 03:14:43 +03:00
Nedko Arnaudov 046563f840 daemon: Partial fix for #86
Don't use jack ids for associating client in jack graph with client in vgraph
because jack ids can change (apps can create clients in random order).
jack ids are not valid after jack server stop

This changeset switches to interlinking the two client by each one storing uuid of the other.
2010-05-12 04:25:39 +03:00
Nedko Arnaudov 3126bbdb5d daemon: when destroying room, remove its hidden app ports. Fixes #87
If ports stay hidden in JACK graph and they get reused, no vgraph will exist
2010-05-10 22:33:40 +03:00
Nedko Arnaudov d8135a5117 daemon: wait room cleanup before destroying it. Fix for #81 and #83 2010-05-09 16:00:28 +03:00
Nedko Arnaudov b82728b36a daemon: properly count number of owned jack clients
jmcore clients are not counted on appear so they should not be counted on disappear too
2010-05-09 15:48:27 +03:00
Nedko Arnaudov 7c10be38cf daemon: coherent naming of studio related functions 2010-05-05 00:35:10 +03:00
Nedko Arnaudov c2c96d1fa4 daemon: Fix invalid memory access
This fixes negative pid reports on 32bit systems
2010-04-24 16:56:20 +03:00
Nedko Arnaudov 2923a9772d daemon: fix wrong goto that was causing warning
../daemon/virtualizer.c:437: error: 'is_a2j' may be used uninitialized in this function
2010-04-11 22:43:32 +03:00
Nedko Arnaudov 245897bc6d daemon: jmcore support in virtualizer 2010-04-11 22:24:41 +03:00
Nedko Arnaudov 31f6cb939b daemon: room-studio port creation through jmcore
virtualizer does not know about jmcore yet
2010-04-11 16:45:30 +03:00
Nedko Arnaudov c7379123eb remove extra line 2010-04-05 17:17:23 +03:00
Nedko Arnaudov c78c4c6483 daemon: register virtualizer graph connection handlers for rooms 2010-04-05 04:18:24 +03:00
Nedko Arnaudov e498a65b6f daemon: fix use of uninitialized vars 2010-04-04 21:51:47 +03:00
Nedko Arnaudov 9f3f884c4d daemon: improve log messages and add TODO comments 2010-04-04 21:30:25 +03:00
Nedko Arnaudov de772730a5 daemon: fix port lifecycle problem that was causing crash
There are three types of ports depeneding on references to them:
 * ports that are referenced from jack and studio graphs
 * ports that are referenced from jack and room graphs
 * studio-room link ports that are referenced from studio and room graphs

The old approach was to destroy ports when removing references from jack graph.
Studio-room link ports were destroyed when removing the room.
However this caused double free when removing app ports that appear in jack and
room graphs.

The introduced implementation uses reference counting of graph references to ports.
Temporary references (like the one returned by port constructor and graph_get_port())
are not tracked.
2010-04-04 21:08:20 +03:00
Nedko Arnaudov d161a68191 daemon: make the room app ports appear in the room graph instead of studio graph 2010-04-04 04:03:40 +03:00
Nedko Arnaudov 06fa6965b4 daemon: fit app search by pid that got broken in 454346ce65 2010-04-04 00:35:40 +03:00
Nedko Arnaudov 22aa3feb67 daemon: Fix comment 2010-04-04 00:31:40 +03:00
Nedko Arnaudov e2c0400548 daemon: add commented logs 2010-04-04 00:31:14 +03:00
Nedko Arnaudov 3e5b69c481 daemon: iterate studio graphs instead of app supervisors
The callback has both app supervisor and graph parameters.
The graph parameter is needed so virtualizer can know where to add clients/ports
2010-04-03 22:25:28 +03:00
Nedko Arnaudov 496f8712e2 fix typo in comment 2010-04-03 22:07:55 +03:00
Nedko Arnaudov 454346ce65 daemon: search client pids in room supervisors too 2010-04-03 20:33:20 +03:00
Nedko Arnaudov e22b7a2d69 daemon: remove useless client properties 2010-03-24 02:02:45 +02:00
Nedko Arnaudov 093af66573 rename graph clients when app is renamed
this fixes autoconnection too because hidden clients are searched by name
2009-12-26 22:46:20 +02:00
Nedko Arnaudov b42455029a daemon: fix warning 2009-12-21 21:38:25 +02:00
Nedko Arnaudov 3bec987ea4 handle port renames. closes #32 2009-12-21 20:46:14 +02:00
Nedko Arnaudov 128590f5bf daemom: for now, ignore clients when they are more than one per app
asserting is not good in this case...
2009-12-16 03:12:41 +02:00
Nedko Arnaudov b5565fd398 move proxy implementations to new /proxies directory 2009-12-13 18:10:57 +02:00
Nedko Arnaudov d76dcc4b20 daemon: Fix #33
JACK graph connections are always visible and match the actual
JACK graph connections. So the logic for hiding connections when
they are removed should be disabled for JACK graphs. See
also commit 5ef9e1e006 where this
bug was intoduced.
2009-12-12 21:55:41 +02:00
Nedko Arnaudov a1670050dc daemon: dont assert when jackd goes crazy 2009-12-12 20:07:59 +02:00
Nedko Arnaudov a10355eb4e daemon: fix handling of a2j ports for alsa seq inout ports. Fixes #36 2009-12-12 15:13:53 +02:00
Nedko Arnaudov 4a2c32b36e daemon: fix use of uninitialized variable 2009-12-12 13:18:08 +02:00
Nedko Arnaudov fde1b8f19b daemon: properly check for system client 2009-12-12 01:32:49 +02:00
Nedko Arnaudov cf3d6bd277 daemon: fix restoring of a2j clients/ports/connections (again) 2009-12-12 01:15:48 +02:00
Nedko Arnaudov ff45e7fe56 daemon: add some logs 2009-12-12 01:14:51 +02:00