projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
1080ae0
)
on CDR date parse, consider 1970-01-01 NULL like 1900-01-01, RT#4081
author
ivan
<ivan>
Tue, 7 Jul 2009 00:47:58 +0000
(
00:47
+0000)
committer
ivan
<ivan>
Tue, 7 Jul 2009 00:47:58 +0000
(
00:47
+0000)
FS/FS/cdr.pm
patch
|
blob
|
history
diff --git
a/FS/FS/cdr.pm
b/FS/FS/cdr.pm
index
96132ec
..
418519e
100644
(file)
--- a/
FS/FS/cdr.pm
+++ b/
FS/FS/cdr.pm
@@
-766,8
+766,8
@@
sub _cdr_date_parse {
die "unparsable date: $date"; #maybe we shouldn't die...
}
die "unparsable date: $date"; #maybe we shouldn't die...
}
- return '' if
$year == 1900
&& $mon == 1 && $day == 1
- && $hour == 0
&& $min == 0 && $sec == 0;
+ return '' if
( $year == 1900 || $year == 1970 )
&& $mon == 1 && $day == 1
+ && $hour == 0 && $min == 0 && $sec == 0;
if ($options{gmt}) {
timegm($sec, $min, $hour, $day, $mon-1, $year);
if ($options{gmt}) {
timegm($sec, $min, $hour, $day, $mon-1, $year);