Re: grep(1): fix printing trailing context when using -m

2022-05-29 Thread Omar Polo
Dave Voutila wrote: > I noticed this today while grepping through a very long kdump output and > using something like: > > $ fgrep -n -m2 -C2 'kevent -1' dump.txt > 641- 31513 vmd RET sendmsg 1848/0x738 > 642- 31513 vmd CALL kevent(5,0x90d4c2e4000,1,0x90d8004a000,2048,0) > 643: 31513

grep(1): fix printing trailing context when using -m

2022-05-29 Thread Dave Voutila
I noticed this today while grepping through a very long kdump output and using something like: $ fgrep -n -m2 -C2 'kevent -1' dump.txt 641- 31513 vmd RET sendmsg 1848/0x738 642- 31513 vmd CALL kevent(5,0x90d4c2e4000,1,0x90d8004a000,2048,0) 643: 31513 vmd RET kevent -1 errno 4 I