Fixed lock-unlock code.
Merge branch 'master' of https://github.com/corehacker/c-modules.git