summaryrefslogtreecommitdiff
path: root/gr-audio-jack/src/audio_jack_sink.cc
diff options
context:
space:
mode:
authorTom Rondeau2010-11-09 22:08:58 -0500
committerTom Rondeau2010-11-09 22:08:58 -0500
commit5d1baa5a96e3dac0756571da9fc115dba14bbbff (patch)
tree102377628881fb7554c008c441737ed286a28b68 /gr-audio-jack/src/audio_jack_sink.cc
parent6fc05897572c82ebb523d0ab0ac4cf763d00cb4a (diff)
downloadgnuradio-5d1baa5a96e3dac0756571da9fc115dba14bbbff.tar.gz
gnuradio-5d1baa5a96e3dac0756571da9fc115dba14bbbff.tar.bz2
gnuradio-5d1baa5a96e3dac0756571da9fc115dba14bbbff.zip
Updating audio_jack to new interface for creating a client. Fixes depricated warning.
Diffstat (limited to 'gr-audio-jack/src/audio_jack_sink.cc')
-rw-r--r--gr-audio-jack/src/audio_jack_sink.cc13
1 files changed, 9 insertions, 4 deletions
diff --git a/gr-audio-jack/src/audio_jack_sink.cc b/gr-audio-jack/src/audio_jack_sink.cc
index 6e39135c9..f28fddc34 100644
--- a/gr-audio-jack/src/audio_jack_sink.cc
+++ b/gr-audio-jack/src/audio_jack_sink.cc
@@ -105,12 +105,17 @@ audio_jack_sink::audio_jack_sink (int sampling_rate,
d_nunderuns (0)
{
#ifndef NO_PTHREAD
- pthread_cond_init(&d_ringbuffer_ready, NULL);;
- pthread_mutex_init(&d_jack_process_lock, NULL);
+ pthread_cond_init(&d_ringbuffer_ready, NULL);;
+ pthread_mutex_init(&d_jack_process_lock, NULL);
#endif
-
+
// try to become a client of the JACK server
- if ((d_jack_client = jack_client_new (d_device_name.c_str ())) == 0) {
+ jack_options_t options = JackNullOption;
+ jack_status_t status;
+ const char *server_name = NULL;
+ if ((d_jack_client = jack_client_open (d_device_name.c_str (),
+ options, &status,
+ server_name)) == NULL) {
fprintf (stderr, "audio_jack_sink[%s]: jack server not running?\n",
d_device_name.c_str());
throw std::runtime_error ("audio_jack_sink");