📄 user_onhook.c
字号:
#include <srllib.h>
#include <dxxxlib.h>
#include <dm3comp.h>
#include <stdio.h>
BOOL pstnOnHook(int channel);
void user_onhook(int channel)
{
BOOL rBool;
//使用同步停止通道
if (dx_stopch(channel, EV_SYNC)==-1) {
printf("Error in stop channel %d !\n",channel);
}
/* Set PSTN on-hook */
rBool = pstnOnHook(channel);
if(rBool==DM3FAIL) {
//gateFATAL(channel,(Session[channel].LogFile,"\tError setting on hook for channel %d in Wait For Disconnect\n",
// channel));
printf("Error setting on hook for channel %d in Wait For Disconnect\n",channel);
if (dx_sethook(channel,DX_ONHOOK,EV_SYNC) == -1) {
printf("Error in set channel %d on hook SYNC!\n",channel);
}
// gateUpdate(pCamelSession,GATE_WAIT_CALL);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -