Unlock mutex on thread cancellation
Merge pull request #1 from ClearwaterCore/CCV4-WIP

Unlock mutex on thread cancellation