SHARE
TWEET

Untitled

a guest May 26th, 2019 67 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Lock()
  2. {
  3.     counter++;
  4.     if(counter == 1)
  5.     {
  6.         m.lock();
  7.     }
  8. }
  9. Unlock()
  10. {
  11.     counter--;
  12.     if(counter == 0)
  13.     {
  14.         m.unlock();
  15.     }
  16. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top