mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-02 19:29:31 +00:00
update to allow args to enum dialplan for lookups.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4074 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
0ed9ebe492
commit
8d45c2e90a
@ -521,6 +521,7 @@ static switch_caller_extension_t *enum_dialplan_hunt(switch_core_session_t *sess
|
|||||||
enum_record_t *results, *rp;
|
enum_record_t *results, *rp;
|
||||||
switch_channel_t *channel = switch_core_session_get_channel(session);
|
switch_channel_t *channel = switch_core_session_get_channel(session);
|
||||||
enum_route_t *rtp;
|
enum_route_t *rtp;
|
||||||
|
char *dp = (char *) arg;
|
||||||
|
|
||||||
assert(channel != NULL);
|
assert(channel != NULL);
|
||||||
|
|
||||||
@ -528,7 +529,7 @@ static switch_caller_extension_t *enum_dialplan_hunt(switch_core_session_t *sess
|
|||||||
|
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "ENUM Lookup on %s\n", caller_profile->destination_number);
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "ENUM Lookup on %s\n", caller_profile->destination_number);
|
||||||
|
|
||||||
if (enum_lookup(globals.root, caller_profile->destination_number, &results) == SWITCH_STATUS_SUCCESS) {
|
if (enum_lookup(switch_strlen_zero(dp) ? globals.root : dp, caller_profile->destination_number, &results) == SWITCH_STATUS_SUCCESS) {
|
||||||
if ((extension = switch_caller_extension_new(session, caller_profile->destination_number, caller_profile->destination_number)) == 0) {
|
if ((extension = switch_caller_extension_new(session, caller_profile->destination_number, caller_profile->destination_number)) == 0) {
|
||||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "memory error!\n");
|
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "memory error!\n");
|
||||||
free_results(&results);
|
free_results(&results);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user