Skip to content

Commit

Permalink
Capital letters are allowed in tokens in syslog.aug
Browse files Browse the repository at this point in the history
  • Loading branch information
raphink committed Sep 13, 2012
1 parent fce1446 commit ad004d0
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lenses/syslog.aug
Expand Up @@ -104,7 +104,7 @@ module Syslog =
(* Variable: token
alphanum or "*"
*)
let token = /([a-z0-9]+|\*)/
let token = /([A-Za-z0-9]+|\*)/

(* Variable: file_r
a file begins with a / and get almost anything else after
Expand Down
14 changes: 14 additions & 0 deletions lenses/tests/test_syslog.aug
Expand Up @@ -299,3 +299,17 @@ daemon.info /var/log/cvsupd.log
set "/hostname/reverse" "" ;
set "/hostname/hostname" "foo.foo.away"
= "-foo.foo.away\n"

(* tokens can contain capital letters *)
test Syslog.lns get "LOCAL5.* -/var/log/foo.log\n" = ?
{ "entry"
{ "selector"
{ "facility" = "LOCAL5" }
{ "level" = "*" }
}
{ "action"
{ "no_sync" }
{ "file" = "/var/log/foo.log" }
}
}

0 comments on commit ad004d0

Please sign in to comment.