diff options
author | Max Kellermann <max@duempel.org> | 2014-03-01 09:19:32 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-03-01 18:48:20 +0100 |
commit | 1e06c66c776e2dca217059d7d94309b0c5431a3f (patch) | |
tree | 64b3bf4c5051fabf9dff5b9d0c3ed73b3d2bb45b /src/thread | |
parent | c73771e3ce7a5866f5ddc70d1cc03acf6a104127 (diff) | |
download | mpd-1e06c66c776e2dca217059d7d94309b0c5431a3f.tar.gz mpd-1e06c66c776e2dca217059d7d94309b0c5431a3f.tar.xz mpd-1e06c66c776e2dca217059d7d94309b0c5431a3f.zip |
java: new helper library for the Android port
Diffstat (limited to 'src/thread')
-rw-r--r-- | src/thread/Thread.cxx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/thread/Thread.cxx b/src/thread/Thread.cxx index 9016680e4..2932d478f 100644 --- a/src/thread/Thread.cxx +++ b/src/thread/Thread.cxx @@ -21,6 +21,10 @@ #include "Thread.hxx" #include "util/Error.hxx" +#ifdef ANDROID +#include "java/Global.hxx" +#endif + bool Thread::Start(void (*_f)(void *ctx), void *_ctx, Error &error) { @@ -102,6 +106,11 @@ Thread::ThreadProc(void *ctx) #endif thread.f(thread.ctx); + +#ifdef ANDROID + Java::DetachCurrentThread(); +#endif + return nullptr; } |