Locking pointer and unlocking
Merge pull request #1 from TheMonkey1415/master

Locking pointer and unlocking