Index: apps/app_dial.c =================================================================== --- apps/app_dial.c (revision 300210) +++ apps/app_dial.c (working copy) @@ -2049,6 +2049,22 @@ } continue; } + /* Send notification to the manager that we have allocated a new channel for dial, + * so that a manager application can see the old and new uniqueId's for this call + * (the manager needs to know this, because all subsequent events for the original + * call will carry this new unique id. Without this message, any manager application + * doesn't have any way to know what channel they apply to) + */ + manager_event( + EVENT_FLAG_CALL, + "ChannelForDial", + "Channel: %s\r\nUniqueid: %s\r\nNewChannel: %s\r\nNewUniqueId: %s\r\n", + tc->name, + tc->uniqueid, + chan->name, + chan->uniqueid + ); + ast_channel_get_device_name(tc, device_name, sizeof(device_name)); if (!ignore_cc) { ast_cc_extension_monitor_add_dialstring(chan, interface, device_name);