Bug#279635: [Logcheck-devel] Bug#279635: logcheck: empty line in `local' file is copied to egrep pattern file

Todd Troxell ttroxell at debian.org
Thu Nov 4 21:39:40 UTC 2004


On Thu, Nov 04, 2004 at 10:45:07AM +0100, Jim Meyering wrote:
> Package: logcheck
> Version: 1.2.30
> Severity: important
> 
> With the installation of logcheck-1.2.30, I started getting hundreds
> of lines of messages every hour.  The problem was that
> I had a blank line in violations.d/local.
> Of course, I shouldn't have had a blank line in the file
> in the first place.
> 
> Here's a patch that fixed it:
> 
> --- /usr/sbin/logcheck.~5~	2004-11-04 10:04:55.000000000 +0100
> +++ /usr/sbin/logcheck	2004-11-04 10:30:21.000000000 +0100
> @@ -615,7 +615,7 @@
>  mkdir $TMPDIR/logoutput \
>      || error "Could not mkdir for log files"
>  if [ ! $LOGFILE ]; then
> -    for file in $(egrep --text -v "(^#|^[[:space:]]\+$)" $LOGFILES_LIST); do
> +    for file in $(egrep --text -v "(^#|^[[:space:]]*$)" $LOGFILES_LIST); do
>  	logoutput "$file"
>      done 
>  elif [ $LOGFILE ]; then

I am confused.  Doesn't line 618 just parse the list of logfiles to be
processed?  How could this cause a blank line in violations.d/local to be a
problem?

Did we get a patch applied in the wrong place?

-- 
[   Todd J. Troxell                                         ,''`.
      Student, Debian GNU/Linux Developer, SysAdmin, Geek  : :' :
      http://debian.org || http://rapidpacket.com/~xtat    `. `' 
                                                             `-     ]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.alioth.debian.org/pipermail/logcheck-devel/attachments/20041104/6398b7ea/attachment.pgp 


More information about the Logcheck-devel mailing list