diff --git a/CHANGES b/CHANGES index b43b2442db..35588656e6 100644 --- a/CHANGES +++ b/CHANGES @@ -33,6 +33,10 @@ Dialplan functions * MailboxExists converted to dialplan function * A new option to Dial() for telling IP phones not to count the call as "missed" when dial times out and cancels. + * Added LOCK(), TRYLOCK(), and UNLOCK(), which provide a single level dialplan + mutex. No deadlocks are possible, as LOCK() only allows a single lock to be + held for any given channel. Also, locks are automatically freed when a + channel is hung up. CLI Changes ----------- diff --git a/funcs/func_lock.c b/funcs/func_lock.c index 477f1c1aa3..e9ac0651b8 100644 --- a/funcs/func_lock.c +++ b/funcs/func_lock.c @@ -200,8 +200,9 @@ static struct ast_custom_function unlock_function = { .name = "UNLOCK", .synopsis = "Unlocks a named mutex", .desc = -"Unlocks a previously locked mutex. Returns 1 if the channel had a lock\n" -"or 0 otherwise.\n", +"Unlocks a previously locked mutex. Note that it is generally unnecessary to\n" +"unlock in a hangup routine, as any lock held is automatically freed when the\n" +"channel is destroyed. Returns 1 if the channel had a lock or 0 otherwise.\n", .syntax = "UNLOCK()", .read = unlock_read, };