mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-03 11:25:35 +00:00
Add missing CEL logging fields to various CEL backends.
Multiple revisions 350555,350571 ........ r350555 | rmudgett | 2012-01-13 11:12:51 -0600 (Fri, 13 Jan 2012) | 12 lines Add missing CEL logging fields to various CEL backends. * Add missing eventextra to cel_psql.c and cel_odbc.c. * Add missing PeerAccount and EventExtra to cel_manager.c. * Add missing userdeftype support for cel_custom.conf.sample and cel_sqlite3_custom.conf.sample. (closes issue ASTERISK-17190) Reported by: Bryant Zimmerman ........ r350571 | rmudgett | 2012-01-13 11:23:57 -0600 (Fri, 13 Jan 2012) | 8 lines Use compatible names for event extra data for various CEL backends. * Change eventextra to extra in cel_psql.c and cel_odbc.c. * Change EventExtra to Extra in cel_manager.c. (issue ASTERISK-17190) ........ Merged revisions 350555,350571 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ........ Merged revisions 350585 from http://svn.asterisk.org/svn/asterisk/branches/10 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@350605 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -61,11 +61,11 @@ static void manager_log(const struct ast_event *event, void *userdata)
|
||||
.version = AST_CEL_EVENT_RECORD_VERSION,
|
||||
};
|
||||
|
||||
if (ast_cel_fill_record(event, &record)) {
|
||||
if (!enablecel) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!enablecel) {
|
||||
if (ast_cel_fill_record(event, &record)) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -90,13 +90,29 @@ static void manager_log(const struct ast_event *event, void *userdata)
|
||||
"UniqueID: %s\r\n"
|
||||
"LinkedID: %s\r\n"
|
||||
"Userfield: %s\r\n"
|
||||
"Peer: %s\r\n",
|
||||
record.event_name, record.account_code, record.caller_id_num,
|
||||
record.caller_id_name, record.caller_id_ani, record.caller_id_rdnis,
|
||||
record.caller_id_dnid, record.extension, record.context, record.channel_name,
|
||||
record.application_name, record.application_data, start_time,
|
||||
ast_cel_get_ama_flag_name(record.amaflag), record.unique_id, record.linked_id,
|
||||
record.user_field, record.peer);
|
||||
"Peer: %s\r\n"
|
||||
"PeerAccount: %s\r\n"
|
||||
"Extra: %s\r\n",
|
||||
record.event_name,
|
||||
record.account_code,
|
||||
record.caller_id_num,
|
||||
record.caller_id_name,
|
||||
record.caller_id_ani,
|
||||
record.caller_id_rdnis,
|
||||
record.caller_id_dnid,
|
||||
record.extension,
|
||||
record.context,
|
||||
record.channel_name,
|
||||
record.application_name,
|
||||
record.application_data,
|
||||
start_time,
|
||||
ast_cel_get_ama_flag_name(record.amaflag),
|
||||
record.unique_id,
|
||||
record.linked_id,
|
||||
record.user_field,
|
||||
record.peer,
|
||||
record.peer_account,
|
||||
record.extra);
|
||||
}
|
||||
|
||||
static int load_config(int reload)
|
||||
|
@@ -438,6 +438,8 @@ static void odbc_log(const struct ast_event *event, void *userdata)
|
||||
ast_copy_string(colbuf, record.peer, sizeof(colbuf));
|
||||
} else if (strcmp(entry->celname, "amaflags") == 0) {
|
||||
snprintf(colbuf, sizeof(colbuf), "%d", record.amaflag);
|
||||
} else if (strcmp(entry->celname, "extra") == 0) {
|
||||
ast_copy_string(colbuf, record.extra, sizeof(colbuf));
|
||||
} else {
|
||||
colbuf[0] = 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user