diff options
Diffstat (limited to 'Alc/backends/jack.c')
-rw-r--r-- | Alc/backends/jack.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Alc/backends/jack.c b/Alc/backends/jack.c index 517f99a4..283df297 100644 --- a/Alc/backends/jack.c +++ b/Alc/backends/jack.c @@ -54,6 +54,7 @@ static const ALCchar jackDevice[] = "JACK Default"; MAGIC(jack_get_ports); \ MAGIC(jack_free); \ MAGIC(jack_get_sample_rate); \ + MAGIC(jack_set_error_function); \ MAGIC(jack_set_process_callback); \ MAGIC(jack_set_buffer_size_callback); \ MAGIC(jack_set_buffer_size); \ @@ -78,6 +79,7 @@ JACK_FUNCS(MAKE_FUNC); #define jack_get_ports pjack_get_ports #define jack_free pjack_free #define jack_get_sample_rate pjack_get_sample_rate +#define jack_set_error_function pjack_set_error_function #define jack_set_process_callback pjack_set_process_callback #define jack_set_buffer_size_callback pjack_set_buffer_size_callback #define jack_set_buffer_size pjack_set_buffer_size @@ -537,6 +539,11 @@ static void ALCjackPlayback_unlock(ALCjackPlayback *self) } +static void jack_msg_handler(const char *message) +{ + WARN("%s\n", message); +} + typedef struct ALCjackBackendFactory { DERIVE_FROM_TYPE(ALCbackendFactory); } ALCjackBackendFactory; @@ -552,7 +559,10 @@ static ALCboolean ALCjackBackendFactory_init(ALCjackBackendFactory* UNUSED(self) if(!GetConfigValueBool(NULL, "jack", "spawn-server", 0)) ClientOptions |= JackNoStartServer; + + jack_set_error_function(jack_msg_handler); client = jack_client_open("alsoft", ClientOptions, &status, NULL); + jack_set_error_function(NULL); if(client == NULL) { WARN("jack_client_open() failed, 0x%02x\n", status); |