projects
/
asterisk/asterisk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
485b1d9
)
Ensure that "calldate" is acceptable for a column name.
author
Tilghman Lesher
<tilghman@meg.abyt.es>
Sat, 10 May 2008 14:19:41 +0000
(14:19 +0000)
committer
Tilghman Lesher
<tilghman@meg.abyt.es>
Sat, 10 May 2008 14:19:41 +0000
(14:19 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@115596
65c4cc65
-6c06-0410-ace0-
fbb531ad65f3
cdr/cdr_pgsql.c
patch
|
blob
|
history
diff --git
a/cdr/cdr_pgsql.c
b/cdr/cdr_pgsql.c
index
8e4e176
..
ffc5203
100644
(file)
--- a/
cdr/cdr_pgsql.c
+++ b/
cdr/cdr_pgsql.c
@@
-140,6
+140,9
@@
static int pgsql_log(struct ast_cdr *cdr)
AST_RWLIST_TRAVERSE(&psql_columns, cur, list) {
/* For fields not set, simply skip them */
ast_cdr_getvar(cdr, cur->name, &value, buf, sizeof(buf), 0, 0);
+ if (strcmp(cur->name, "calldate") == 0 && !value) {
+ ast_cdr_getvar(cdr, "start", &value, buf, sizeof(buf), 0, 0);
+ }
if (!value) {
if (cur->notnull && !cur->hasdefault) {
/* Field is NOT NULL (but no default), must include it anyway */