summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorHerb Lewis <herb@samba.org>2001-08-27 18:24:04 +0000
committerHerb Lewis <herb@samba.org>2001-08-27 18:24:04 +0000
commit1d726fe0e054be9017309186c24b24d032e85636 (patch)
tree6335f7afe66de8abd08072548b14346a0f768492 /source3
parent05c0ca23557cf329730887c37cc83fcffdd76796 (diff)
downloadsamba-1d726fe0e054be9017309186c24b24d032e85636.tar.gz
samba-1d726fe0e054be9017309186c24b24d032e85636.tar.bz2
samba-1d726fe0e054be9017309186c24b24d032e85636.zip
new logs use abbreviated month names. Add this to date conversion
(This used to be commit 8021669b167053b5500f035c9c50d1327d73c232)
Diffstat (limited to 'source3')
-rwxr-xr-xsource3/script/scancvslog.pl18
1 files changed, 17 insertions, 1 deletions
diff --git a/source3/script/scancvslog.pl b/source3/script/scancvslog.pl
index b1114f5706..c39f9111c1 100755
--- a/source3/script/scancvslog.pl
+++ b/source3/script/scancvslog.pl
@@ -37,7 +37,19 @@ open(INFILE,@ARGV[0]) || die "Unable to open @ARGV[0]\n";
"September", 8,
"October", 9,
"November", 10,
- "December", 11
+ "December", 11,
+ "Jan", 0,
+ "Feb", 1,
+ "Mar", 2,
+ "Apr", 3,
+ "May", 4,
+ "Jun", 5,
+ "Jul", 6,
+ "Aug", 7,
+ "Sep", 8,
+ "Oct", 9,
+ "Nov", 10,
+ "Dec", 11
);
$Starttime = (@ARGV[1]) ? &make_time(@ARGV[1]) : 0;
@@ -45,6 +57,10 @@ $Tagvalue = @ARGV[2];
while (&get_entry) {
$_=$Entry[0];
+# get rid of extra white space
+ s/\s+/ /g;
+# get rid of any time string in date
+ s/ \d\d:\d\d:\d\d/,/;
s/^Date:\s*\w*\s*(\w*)\s*(\w*),\s*(\w*).*/$1 $2 $3/;
$Testtime = &make_time($_);
$Testtag = &get_tag;