diff --git a/core/app.cc b/core/app.cc index c2a99166..0997fdbb 100644 --- a/core/app.cc +++ b/core/app.cc @@ -20,6 +20,7 @@ #include "libc/pthread.hh" #include #define __APP_SOL__ +#define __WORK_AROUND__ using namespace boost::range; @@ -254,6 +255,10 @@ int application::join() _joiner = sched::thread::current(); _runtime.reset(); +#ifdef __WORK_AROUND__ + debug_always("work-around solution\n" ); + sched::thread::current()->wake_with( [&] { _terminated.store(true); }); +#endif sched::thread::wait_until([&] { return _terminated.load(); }); _termination_request_callbacks.clear(); diff --git a/linux.cc b/linux.cc index 8dd77cb7..8c9f541b 100644 --- a/linux.cc +++ b/linux.cc @@ -342,7 +342,7 @@ long syscall(long number, ...) sched::fpu_lock fpu; SCOPE_LOCK(fpu); - debug_always("syscall(): system call %d called by tid:%u\n", number, sched::thread::current()->id()); + //debug_always("syscall(): system call %d called by tid:%u\n", number, sched::thread::current()->id()); switch (number) { SYSCALL2(open, const char *, int); SYSCALL3(read, int, char *, size_t);