mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-14 00:24:05 +00:00
Pass concept of status back, permit "leaveempty" to work with static agents who are not loggedon (bug #2719)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@4106 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -19,6 +19,7 @@
|
||||
#include <asterisk/config.h>
|
||||
#include <asterisk/cli.h>
|
||||
#include <asterisk/utils.h>
|
||||
#include <asterisk/causes.h>
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
#include <errno.h>
|
||||
@@ -753,7 +754,7 @@ static struct ast_channel *alsa_new(struct chan_alsa_pvt *p, int state)
|
||||
return tmp;
|
||||
}
|
||||
|
||||
static struct ast_channel *alsa_request(const char *type, int format, void *data)
|
||||
static struct ast_channel *alsa_request(const char *type, int format, void *data, int *cause)
|
||||
{
|
||||
int oldformat = format;
|
||||
struct ast_channel *tmp=NULL;
|
||||
@@ -765,6 +766,7 @@ static struct ast_channel *alsa_request(const char *type, int format, void *data
|
||||
ast_mutex_lock(&alsalock);
|
||||
if (alsa.owner) {
|
||||
ast_log(LOG_NOTICE, "Already have a call on the ALSA channel\n");
|
||||
*cause = AST_CAUSE_BUSY;
|
||||
} else {
|
||||
tmp= alsa_new(&alsa, AST_STATE_DOWN);
|
||||
if (!tmp) {
|
||||
|
Reference in New Issue
Block a user