Modified: freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c (14642 => 14643)
--- freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c 2009-08-26 16:17:01 UTC (rev 14642)
+++ freeswitch/trunk/src/mod/applications/mod_dptools/mod_dptools.c 2009-08-26 16:29:47 UTC (rev 14643)
@@ -938,12 +938,17 @@
{
switch_event_t *event;
char *buf;
+ int level = SWITCH_LOG_INFO;
+ if (data) {
+ level = switch_log_str2level(data);
+ }
+
if (switch_event_create_plain(&event, SWITCH_EVENT_CHANNEL_DATA) == SWITCH_STATUS_SUCCESS) {
switch_channel_event_set_data(switch_core_session_get_channel(session), event);
switch_event_serialize(event, &buf, SWITCH_FALSE);
switch_assert(buf);
- switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_INFO, "CHANNEL_DATA:\n%s\n", buf);
+ switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), level, "CHANNEL_DATA:\n%s\n", buf);
switch_event_destroy(&event);
free(buf);
}