summaryrefslogtreecommitdiffstats
path: root/chan_lcr.c
diff options
context:
space:
mode:
authorAndreas Eversberg2009-03-29 13:09:59 +0200
committerAndreas Eversberg2009-03-29 13:09:59 +0200
commit14a1adb4fc440ace98a8b9aef21a5d30f5d7fe6e (patch)
treec1a351787fc072677c242f5ed42f7a90fbca1848 /chan_lcr.c
parentAdded layer1 hold feature. Requires new mISDN and mISDNuser package from git. (diff)
downloadlcr-14a1adb4fc440ace98a8b9aef21a5d30f5d7fe6e.tar.gz
lcr-14a1adb4fc440ace98a8b9aef21a5d30f5d7fe6e.tar.xz
lcr-14a1adb4fc440ace98a8b9aef21a5d30f5d7fe6e.zip
chan_lcr: fixed compile problems with newer versions of asterisk
Diffstat (limited to 'chan_lcr.c')
-rw-r--r--chan_lcr.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/chan_lcr.c b/chan_lcr.c
index b3c42cc..5c23337 100644
--- a/chan_lcr.c
+++ b/chan_lcr.c
@@ -129,6 +129,8 @@ it is called from ast_channel process which has already locked ast_channel.
#define HAVE_ATTRIBUTE_always_inline 1
#define HAVE_ARPA_INET_H 1
#define HAVE_TIMERSUB 1
+#define HAVE_STRTOQ 1
+#define HAVE_INET_ATON 1
#include <asterisk/compiler.h>
#ifdef LCR_FOR_ASTERISK
@@ -503,7 +505,12 @@ void apply_opt(struct chan_call *call, char *data)
ast_dsp_set_features(call->dsp, DSP_FEATURE_DTMF_DETECT| DSP_FEATURE_FAX_CNG_DETECT);
#endif
#ifdef LCR_FOR_ASTERISK
+ #ifdef DSP_FEATURE_DTMF_DETECT
ast_dsp_set_features(call->dsp, DSP_FEATURE_DTMF_DETECT| DSP_FEATURE_FAX_DETECT);
+ #else
+ ast_dsp_set_features(call->dsp, DSP_FEATURE_DIGIT_DETECT| DSP_FEATURE_FAX_DETECT);
+ #endif
+
#endif
if (!call->trans)
#ifdef LCR_FOR_CALLWEAVER
@@ -2107,7 +2114,7 @@ static int lcr_write(struct ast_channel *ast, struct ast_frame *f)
return -1;
}
if (call->bchannel && f->samples)
- bchannel_transmit(call->bchannel, (unsigned char *)f->data, f->samples);
+ bchannel_transmit(call->bchannel, *((unsigned char **)&(f->data)), f->samples);
ast_mutex_unlock(&chan_lock);
return 0;
}