diff options
author | sletz <sletz@0c269be4-1314-0410-8aa9-9f06e86f4224> | 2009-12-11 10:32:28 +0000 |
---|---|---|
committer | sletz <sletz@0c269be4-1314-0410-8aa9-9f06e86f4224> | 2009-12-11 10:32:28 +0000 |
commit | 01805ee73507ff343cbcc0f75fc1d286af862dc0 (patch) | |
tree | cd009407ae51a2209b877b83936b990b2b0b9128 | |
parent | a46d156ea3a18d0d98404c4c66413473b2697fcc (diff) | |
download | jack2-01805ee73507ff343cbcc0f75fc1d286af862dc0.tar.gz |
Back to old method of server channel close on OSX pre Snow Leopard systems.
git-svn-id: http://subversion.jackaudio.org/jack/jack2/trunk/jackmp@3855 0c269be4-1314-0410-8aa9-9f06e86f4224
-rw-r--r-- | macosx/JackMachServerChannel.cpp | 5 | ||||
-rw-r--r-- | macosx/JackMachServerNotifyChannel.cpp | 4 |
2 files changed, 9 insertions, 0 deletions
diff --git a/macosx/JackMachServerChannel.cpp b/macosx/JackMachServerChannel.cpp index 6f614d3a..fcf4fe8c 100644 --- a/macosx/JackMachServerChannel.cpp +++ b/macosx/JackMachServerChannel.cpp @@ -58,7 +58,12 @@ int JackMachServerChannel::Open(const char* server_name, JackServer* server) void JackMachServerChannel::Close() { jack_log("JackMachServerChannel::Close"); + #ifdef MAC_OS_X_VERSION_10_5 + // Exception does not work in this case on pre Snow Loopard systems, see JackMachServerNotifyChannel::NotifyQuit() + fThread.Kill(); + #else fThread.Stop(); + #endif fServerPort.DestroyPort(); } diff --git a/macosx/JackMachServerNotifyChannel.cpp b/macosx/JackMachServerNotifyChannel.cpp index 378cdfd4..f55ce09e 100644 --- a/macosx/JackMachServerNotifyChannel.cpp +++ b/macosx/JackMachServerNotifyChannel.cpp @@ -55,10 +55,14 @@ void JackMachServerNotifyChannel::Notify(int refnum, int notify, int value) void JackMachServerNotifyChannel::NotifyQuit() { + #ifdef MAC_OS_X_VERSION_10_5 + // Nothing : since exception does not work in this case on pre Snow Loopard systems, see JackMachServerChannel::Close() + #else kern_return_t res = rpc_jack_client_rt_notify(fClientPort.GetPort(), -1, kQUIT, 0, 0); if (res != KERN_SUCCESS) { jack_error("Could not write request ref = %d notify = %d err = %s", -1, kQUIT, mach_error_string(res)); } +#endif } } // end of namespace |