Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

LOCK()

Synopsis

Attempt to obtain a named mutex.

Description

Attempts to grab a named lock exclusively, and prevents other channels from obtaining the same lock. LOCK will wait for the lock to become available. Returns 1 if the lock was obtained or 0 on error.

Info
titleNote

To avoid the possibility of a deadlock, LOCK will only attempt to obtain the lock for 3 seconds if the channel already has another lock.

Info
titleNote

If live_dangerously in asterisk.conf is set to no, this function can only be executed from the dialplan, and not directly from external protocols.

Syntax

No Format
LOCK(lockname)
Arguments
  • lockname

See Also

Import Version

This documentation was imported from Asterisk Version SVN-branch-11-r403917