mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 15:45:18 +00:00
Fixed autopatch so that it would take digits from link peer.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3322 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
* Asterisk -- A telephony toolkit for Linux.
|
* Asterisk -- A telephony toolkit for Linux.
|
||||||
*
|
*
|
||||||
* Radio Repeater / Remote Base program
|
* Radio Repeater / Remote Base program
|
||||||
* version 0.9 6/26/04
|
* version 0.10 6/26/04
|
||||||
*
|
*
|
||||||
* Copyright (C) 2002-2004, Jim Dixon, WB6NIL
|
* Copyright (C) 2002-2004, Jim Dixon, WB6NIL
|
||||||
*
|
*
|
||||||
@@ -110,7 +110,7 @@ enum {REM_LOWPWR,REM_MEDPWR,REM_HIPWR};
|
|||||||
#include <tonezone.h>
|
#include <tonezone.h>
|
||||||
#include <linux/zaptel.h>
|
#include <linux/zaptel.h>
|
||||||
|
|
||||||
static char *tdesc = "Radio Repeater / Remote Base version 0.9 06/26/2004";
|
static char *tdesc = "Radio Repeater / Remote Base version 0.10 06/26/2004";
|
||||||
static char *app = "Rpt";
|
static char *app = "Rpt";
|
||||||
|
|
||||||
static char *synopsis = "Radio Repeater/Remote Base Control System";
|
static char *synopsis = "Radio Repeater/Remote Base Control System";
|
||||||
@@ -1104,8 +1104,6 @@ int seq;
|
|||||||
struct rpt_link *l;
|
struct rpt_link *l;
|
||||||
struct ast_frame wf;
|
struct ast_frame wf;
|
||||||
|
|
||||||
/* if we are a remote, we dont want to do this */
|
|
||||||
if (myrpt->remote) return;
|
|
||||||
wf.frametype = AST_FRAME_TEXT;
|
wf.frametype = AST_FRAME_TEXT;
|
||||||
wf.subclass = 0;
|
wf.subclass = 0;
|
||||||
wf.offset = 0;
|
wf.offset = 0;
|
||||||
@@ -1169,6 +1167,27 @@ struct ast_frame wf;
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
ast_mutex_lock(&myrpt->lock);
|
ast_mutex_lock(&myrpt->lock);
|
||||||
|
if (myrpt->callmode == 1)
|
||||||
|
{
|
||||||
|
myrpt->exten[myrpt->cidx++] = c;
|
||||||
|
myrpt->exten[myrpt->cidx] = 0;
|
||||||
|
/* if this exists */
|
||||||
|
if (ast_exists_extension(myrpt->pchannel,myrpt->ourcontext,myrpt->exten,1,NULL))
|
||||||
|
{
|
||||||
|
myrpt->callmode = 2;
|
||||||
|
rpt_telemetry(myrpt,PROC,NULL);
|
||||||
|
}
|
||||||
|
/* if can continue, do so */
|
||||||
|
if (!ast_canmatch_extension(myrpt->pchannel,myrpt->ourcontext,myrpt->exten,1,NULL))
|
||||||
|
{
|
||||||
|
/* call has failed, inform user */
|
||||||
|
myrpt->callmode = 4;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ((myrpt->callmode == 2) || (myrpt->callmode == 3))
|
||||||
|
{
|
||||||
|
myrpt->mydtmf = c;
|
||||||
|
}
|
||||||
if (c == '*')
|
if (c == '*')
|
||||||
{
|
{
|
||||||
myrpt->rem_dtmfidx = 0;
|
myrpt->rem_dtmfidx = 0;
|
||||||
|
Reference in New Issue
Block a user