From 4a48bbf0f799cc770461c3c2bc88f4b28a92c462 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Wed, 14 Feb 2007 15:32:02 +0000 Subject: [PATCH] the guy on the mailing list had a good idea, add a message in dingalaing announcing the caller id as a chat message, added, but not testesd...can someone test this? git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4258 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/endpoints/mod_dingaling/mod_dingaling.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/mod/endpoints/mod_dingaling/mod_dingaling.c b/src/mod/endpoints/mod_dingaling/mod_dingaling.c index f5fd291987..24704da798 100644 --- a/src/mod/endpoints/mod_dingaling/mod_dingaling.c +++ b/src/mod/endpoints/mod_dingaling/mod_dingaling.c @@ -1529,6 +1529,7 @@ static switch_call_cause_t channel_outgoing_channel(switch_core_session_t *sessi char *dnis = NULL; char workspace[1024] = ""; char *p, *u, ubuf[512] = "", *user = NULL;; + char *cid_msg = NULL; switch_copy_string(workspace, outbound_profile->destination_number, sizeof(workspace)); profile_name = workspace; @@ -1630,6 +1631,10 @@ static switch_call_cause_t channel_outgoing_channel(switch_core_session_t *sessi tech_pvt->us = switch_core_session_strdup(*new_session, user); tech_pvt->them = switch_core_session_strdup(*new_session, full_id); ldl_session_create(&dlsession, mdl_profile->handle, sess_id, full_id, user, LDL_FLAG_OUTBOUND); + if ((cid_msg = switch_mprintf("Incoming Call From %s %s\n", outbound_profile->caller_id_name, outbound_profile->caller_id_number))) { + ldl_handle_send_msg(mdl_profile->handle, tech_pvt->them, tech_pvt->us, "", cid_msg); + free(cid_msg); + } tech_pvt->profile = mdl_profile; ldl_session_set_private(dlsession, *new_session); ldl_session_set_value(dlsession, "dnis", dnis);