diff options
author | Martin Nordholts <enselic@gmail.com> | 2021-01-03 08:04:25 +0100 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2021-06-12 00:16:53 -0700 |
commit | a43c096a4f954cb7290189542d5e232dbac2d1cf (patch) | |
tree | 397961d2a185d3509c7d0cd0c03b7aa88e0f7b32 /src/rmd_jack.c | |
parent | 76e696ff22cdce07c44bede7a3a43ffac5c717d0 (diff) |
Fix jack_client_new() deprecation warning
By inlining its current implementation in libjack:
https://github.com/jackaudio/jack1/blob/2e78fb6c883286287ae514ff0d262a5584ecdd35/libjack/client.c#L1429
The end-result should be that that the behavior of the app remains the
same as before.
Diffstat (limited to 'src/rmd_jack.c')
-rw-r--r-- | src/rmd_jack.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/rmd_jack.c b/src/rmd_jack.c index e1a5a0e..13239bb 100644 --- a/src/rmd_jack.c +++ b/src/rmd_jack.c @@ -146,7 +146,13 @@ int rmdStartJackClient(JackData *jdata) snprintf( pidbuf, 8, "%d", pid ); strcat(rmd_client_name, pidbuf); - if ((jdata->client = jack_client_new(rmd_client_name)) == 0) { + jack_options_t options = JackUseExactName; + + if (getenv ("JACK_START_SERVER") == NULL) { + options |= JackNoStartServer; + } + + if ((jdata->client = jack_client_open(rmd_client_name, options, NULL)) == 0) { fprintf(stderr, "Could not create new client!\n" "Make sure that Jack server is running!\n"); return 15; |