mmux termination synchronicity

- When multiplexer is signaled to terminate, the multiplexer threads run till
  all signals are detached.
- Implement mmux::wait().