s4cmd.py
def synchronized(func):
  '''Decorator to synchronize function.'''
  func.__lock__ = threading.Lock()
  def synced_func(*args, **kargs):
    with func.__lock__:
      return func(*args, **kargs)
  return synced_func
def synchronized(func):
  '''Decorator to synchronize function.'''
  func.__lock__ = threading.Lock()
  def synced_func(*args, **kargs):
    with func.__lock__:
      return func(*args, **kargs)
  return synced_func
def synchronized ( func ) : func . __lock__ = threading . Lock ( ) def synced_func ( * args , * * kargs ) : with func . __lock__ : return func ( * args , * * kargs ) return synced_func
Decorator to synchronize function.
Decorator to synchronize function .