Recent Posts
None | 27 sec ago
None | 28 sec ago
C++ | 31 sec ago
None | 32 sec ago
None | 35 sec ago
PHP | 41 sec ago
C++ | 54 sec ago
TCL | 57 sec ago
None | 1 min ago
None | 1 min ago
Sitereport
Find cool info about any domain on the internet?
visit sitereport
Free Subdomains
Want a pastebin.com sub-domain for your community?
learn more...
What is pastebin?
Pastebin is a website that hosts all your text & code on dedicated servers for easy sharing.
learn more...
Learn a little bit about the new Pastebin.com on our help page. hide message
By bitplane on the 9th of Feb 2010 10:40:03 PM Download | Raw | Embed | Report
  1.  
  2. def synchronized(f):
  3.     def blockingFunction(self, *args, **kwargs):
  4.         self.lock.acquire()
  5.         try:
  6.             return f(self, *args, **kwargs)
  7.         finally:
  8.             self.lock.release()
  9.     return blockingFunction
Submit a correction or amendment below. Make A New Post
To highlight particular lines, prefix each line with @h@
Syntax highlighting:
Post expiration:
Post exposure:
Name / Title:
Email: