bug-grep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#56843: grep mangling lines


From: Paul Eggert
Subject: bug#56843: grep mangling lines
Date: Sat, 30 Jul 2022 11:17:43 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0

I'm not seeing the problem on Ubuntu 22.04 LTS, using grep 3.7 and GNOME Terminal 3.44.0 using VTE 0.68.0 +BIDI +GNUTLS +ICU +SYSTEMD. The output isn't even colored unless I pass something like '--color=always' to 'grep', which leads me to wonder whether you're using an alias for 'grep' instead of the real thing.

Here's how I tried to reproduce the problem. What happens when you try the same thing on your platform? and what is your platform?

$ cat >x <<'EOF'
> 30 23 * * * /usr/bin/freshclam --datadir=/home/dgp/.clamtk/db --log=/home/dgp/.clamtk/db/freshclam.$(/bin/date +\%b-\%d-\%Y).log >/home/dgp/.clamtk/db/freshclam_cron.log 2>&1 ; /usr/local/bin/clamdscan --config-file=/etc/clamav/clamd.conf --reload --log="$HOME/.clamtk/history/$(/bin/date +\%b-\%d-\%Y).log" >>.clamtk/history/clamscan.log 2>&1 ; /usr/local/bin/clamdscan --config-file=/etc/clamav/clamd.conf --quiet --multiscan --fdpass --log="$HOME/.clamtk/history/$(/bin/date +\%b-\%d-\%Y).log" $HOME >>.clamtk/history/clamscan.log 2>&1 # freshclam update and clam-scan
> EOF
$ cat x | grep clam | diff x -
$ e=$(printf '\033')
$ cat x | grep --color=always clam | sed "s/$e\\[[0-9;]*.//g" | diff x -
$ which grep
/usr/bin/grep





reply via email to

[Prev in Thread] Current Thread [Next in Thread]