mirror of
https://github.com/jambonz/sbc-outbound.git
synced 2026-10-09 21:14:05 +00:00
bugfix: proxying device call to other SBC failed
This commit is contained in:
+3
-1
@@ -1,5 +1,6 @@
|
||||
const debug = require('debug')('jambonz:sbc-outbound');
|
||||
const parseUri = require('drachtio-srf').parseUri;
|
||||
const srf = require('drachtio-srf');
|
||||
const Registrar = require('jambonz-mw-registrar');
|
||||
const {selectHostPort} = require('./utils');
|
||||
|
||||
@@ -62,7 +63,8 @@ function route(opts) {
|
||||
//proxy
|
||||
const proxyAddress = selectHostPort(reg.sbcAddress, 'udp');
|
||||
logger.info(`proxying call to SBC at ${proxyAddress}`);
|
||||
req.proxy(`sip:${proxyAddress[1]}`);
|
||||
//req.proxy(`sip:${proxyAddress[1]}`);
|
||||
req.srf.proxyRequest(req, `sip:${proxyAddress[1]}`);
|
||||
return;
|
||||
}
|
||||
req.locals.registration = reg;
|
||||
|
||||
Reference in New Issue
Block a user