I'm currently porting some of my JACK code to internal clients to get rid
of context switching latencies (10 clients x 40us context-switch sums up
to 30% of my time-slice). Anyway, I was trying to make the internal
clients unload themselves automatically after the main control
application (also a JACK client) exits, or gets killed. Is there a
"right" way to do this?
Currently I've put a watchdog-like check into the internal client's
process() callback, which returns 1 if the client wishes to be unloaded.
This should work, according to the docs from inprocess.c:
* This required entry point is called after the client is loaded by
* @param client pointer to JACK client structure.
* @param load_init character string passed to the load operation.
* @return 0 if successful; otherwise jack_finish() will be called and
* the client terminated immediately.
Now, the problem is that the jackd doesn't conform to this description, it
simply prints "internal client ... has failed". What is broken, jackd or